I was wondering if it was possible to virtualize an iPhone's OS on my Mac. Maybe through VMware or another application?
The only way I have heard of is to download the iPhone SDK, it comes with a iPhone emulator.
I can't give an authoritative answer but my feeling is no, for reasons both technical and legal. The iPhone uses an ARM processor which has an instruction set that is not compatible with the Intel x86 instruction set which VMWare et al provide virtualization of.
Further to this, you would likely need to virtualize components other than the processor in order to support many of the APIs exposed by iPhone OS. Technically speaking, all of these issues are probably surmountable, but products such as VMWare are not likely to support this.
IANAL, but to the best of my knowledge it would be against Apple's licensing to execute the iPhone OS code on platforms other than those approved by Apple, virtual or otherwise
Apples idea is that you would use xCode, which allows you to simulate iOS devices like the iPhone by default (although it only allows specific versions unless you have a phone with the desired OS).
for Windows, there is Xamarian Studio Community which works with Visual Studio. it lets you write iOS, Android and Windows Phone apps in C#, but I know very little about it.
in xCode, open the application. Navigate: Window -> Devices (Shift+Command+2), then pick the device (Ie. iPhone 7 iOS 10.1) xCode device selection menu - xCode 8.1