You should provide the exact model of your Mac since that is very important information to provide specific assistance. You can get the exact model by entering the system serial number here:
Check Your Service and Support Coverage - Apple Support
To create a bootable macOS USB installer, you need access to a Mac compatible with one of the supported versions of macOS for your specific Mac (this is why knowing the exact model is important) and follow the instructions in this Apple article:
How to create a bootable installer for macOS - Apple Support
You can use this article to figure out which Apple hardware is compatible with different versions of macOS:
https://eshop.macsales.com/guides/Mac_OS_X_Compatibility
I haven't seen anyone report any success using alternative methods for creating a bootable macOS USB installer even with TransMac. Apple changed the installers several years ago and since that time the only posts I've seen on these forums are from users who cannot boot a USB stick made with TransMac.
If your Mac ever had macOS 10.12.6+ installed, then you can try booting into Internet Recovery Mode using Command + Option + R in order to attempt to access the online macOS installer.
If your Mac shipped with DVDs, then you may need to use them to reinstall macOS. You need at least macOS 10.6+ in order to be able to access and install any later versions of macOS.
You should always prepare ahead of time for these things.