The issue is that Apple wants a big profit cut on each app. If you were allowed to download & run applications on your own computer, then Apple wouldn't get its cut.
Microsoft "allows" people to install emulators in the same sense that Apple "allows" it on macOS, but a quick search confirms that Microsoft does not allow emulators on their app store, nor does Google. (These policies may specifically be for video game emulation, which is mostly what the legal grey area covers.)
It even has Bochs [3]
Or am I misunderstanding something?
[1] https://play.google.com/store/apps/details?id=com.explusalph...
[2] https://play.google.com/store/apps/details?id=org.mupen64plu...
[3] https://play.google.com/store/apps/details?id=net.sourceforg...
Not sure how they're allowed to exist on the app store, but it's been solid for me for a while now.
The rule changed, I think around the time that Swift Playgrounds came out, to add:
> Educational apps designed to teach, develop, or allow students to test executable code may, in limited circumstances, download code provided that such code is not used for other purposes. Such apps must make the source code provided by the Application completely viewable and editable by the user.
There are probably plenty of apps that do interpret downloaded code (the Frotz app to play old text adventures comes to mind) and fly under the radar. But Apple would surely be on the lookout for any kind of emulator, due to the legal risk.