Hi
Here what I do when I get this issue
I get another Mac and install a modern version of macOS on to a usb hard drive ,then on the Mac that won’t install macOS I plug the hard drive in and turn the mac on and hold the ALT button on the keyboard,this will bring you to a screen that lets you select a boot drive ,you now need to select the drive with macOS on it.
You should be in macOS now and download a installer for the version you want ,then you install onto the drive that originally doesn’t want to install.
If this doesn’t work ,I would install superduper(it’s a drive cloner)and clone your usb hard drive to the one that originally wouldn’t take the install.
Sorry about the MASSIVE explanation but if you need any help at all we are all here for you:-)
Thanks:-)