Would Using a Windows VM With a Linux VPS Work?

Hey, I am looking into what VPS I want to use for bottling social media. My bots can only be used in windows. Linux servers are hugely cheaper then windows, so could I just buy a Linux and run VM? How much would this affect the performance? I would assume the base OS would need to have at least 2 gb of ram. I can buy a 8 gb ram Linux server for how much a 2gb windows server is, so even if half goes to the base OS, it'd still be worth it. Would this work?