When an older application is not compatible with a modern OS, a virtual machine can be used to create an environment with an older OS that supports the legacy application. This allows organizations to maintain access to critical historical data or functionality that newer systems might not provide. However, running legacy software on a modern OS without such measures can result in compatibility issues or failure to run.