Mid 2007 iMac wont boot from USB and wont set up
So ive just got a free mid 2007 imac and when i got it it was on that utilities screen, and then i needed to enter in my apple id so i do that but then it gives me an error saying "This item is temporarily not available." so i try to make a bootable installer with my windows 10 pc because i dont have another mac and my friends also dont have one. so i downloaded the MacOS X El Capitan DMG from Apple (thats also the os i was stuck on before) and then i burn it onto an usb stick with TransMac. then it finished but the mac wouldnt find the usb in that boot selector mode and in disk utility the usb has shown up as not bootable. please help, i have repeated this many times and i am so frustrated, i have tried so many things and youtube tutorials and nothing seems to work/the imac just doesnt recognize the usb. sorry for really bad grammar but im so tired right now and im not gonna bother with grammar, sorry.
iMac