There is nothing special about modifying /etc/hosts in a Virtualmin system. It’s not one of our files and not something we modify the behavior of. We only touch it during install if your system doesn’t even have a fully qualified domain name when the installer is run (we’d rather you got that right before the installation so we don’t have to make any changes).
But, this is either not an /etc/hosts file issue (because Webmin and Usermin do not require anything specific of your hosts file), or you have an additional problem with your configuration…hosts file changes almost certainly cannot cause what you’re describing, even if you do it wrong. (But, maybe I’m wrong. I’ve never really messed up a hosts file in significant ways.)