Welcome to the Apple Support Communities.
Congratulations on the new Mac! No. macOS does not transfer, just your data. However, to move your data, the best and easiest way is to restore from your Time Machine backup: Restore your Mac from a backup - Apple Support. You should not use Wi-Fi or any other method as it often fails.
If you do not have a Time Machine backup, you should create one on your old Mac so it can be restored to the new Mac. To start, you need an external hard drive. Here’s an excellent one sold by Apple: G-Technology 4TB G-DRIVE mobile USB-C Portable Hard Drive - Apple. You can then follow the steps in this Apple Support article to setup your Time Machine backup: Back up your Mac with Time Machine - Apple Support.
Once your new Mac is setup with your data migrated, you should setup Time Machine again to keep continuous backups of your data: Back up your Mac with Time Machine - Apple Support. Also, moving forward, I recommend that you use iCloud in addition to Time Machine to sync all your files and photos to all your Apple devices. Although iCloud is not a "true" backup service, iCloud can also act as an emergency off-site backup, but this is why iCloud should be used in addition to Time Machine. Here are some resources on setting up iCloud for Mac:
Cheers,
Jack