(This Announcement subject to updates)
Mojang/Microsoft have released a new Minecraft Launcher, in the form of a Windows Store app that includes the ability to launch java and bedrock (and dungeons) from the same app.
However, the new launcher reads different files and will not upgrade your old ones.
Forge's Installer will handle this automatically for the most recent releases of 1.17.1, but older versions don't have the changes implemented.
The workaround for these versions is to copy the 'launcher_profiles.json' and 'launcher_accounts.json' files, such that the copies have _microsoft_store added to the end of the file name (NOT the file extension!).
These files can be found in your .minecraft folder.
They should read as launcher_profiles_microsoft_store.json and launcher_accounts_microsoft_store.json when you're done.