I haven't tried it but I would think that it would be possible. You would definitely run into some problems though and it wouldn't be a supported configuration.
It might be better to install the mediation server on the physical computer and then virtualize the Exchange UM server, or visa versa.