Malware on Android exists for the following reasons:
First and biggest reason: it has a massive market share. If iOS had Android's market share, you better believe it'd have more malware.
Second biggest reason: Google kinda sucks at curating their app store compared to iOS. This has nothing to do with sideloading. They let far too much malware into the Google Play store thanks to their policy of reporting bad apps rather than actively prescreening apps as rigorously as Apple does. Google really needs to get better at this.
Distant third: OS vulnerabilities. iOS suffers from this too occasionally.
Very distant fourth: sideloading. Way less than 1% of Android users ever enable sideloading. This is not where the majority of Android users are getting their malware. It's by far the least significant attack vector.
As such, I think it's pretty obvious that Apple adding an "enable sideloading" checkbox on iOS would not be a malware disaster anymore than it is on Mac OS X.