It came about because Microsoft deployed what they called "unicode" before UTF-8 was standardized. In Microsoft-land "Unicode" means UTF-16. This isn't great but it's also baked into all the APIs.
They could always use WTF-8 for the filesystem APIs which can encode all WTF-16 strings (i.e. the encoding that Windows actually uses).