Don't a bunch of the newer tools that wrap Virtualization.Framework (which itself wraps/builds on the lower level Hypervisor.framework) already support this?
There's even an example project to do this in code: https://developer.apple.com/documentation/virtualization/run...