The ios being exclusive to MacOS is an Apple made problem though.
So you're paying double in hardware cost because of some decision by Apple that no other platform may compile for ios.
You're right, it is. However knowing that doesn't change it.
I don't believe that you're paying double the hardware cost though. To get a halfway decent non-Apple laptop you need to be paying close to the same price anyway. The current Macs (especially Apple Silicon ones) really are much better quality than virtually (perhaps literally) anything you can get for half their price.
A new Lenovo cost about 3k, and a new Mac costs about that too.
The Lenovo comes with windows (so rails and elixir dev's can't use it)
Mac didn't decide not to support rails, or lock rails devs out of other OS's.