Accidentally made new xbox account when trying to sign in to old one with the same microsoft account
About 2 weeks ago was when I last played minecraft using my normal account, which was connected to my xbox account and therefore my microsoft account, of which I only have one. A week ago, when trying to log in to play bedwars with friends(on pc), I opened the launcher to find was randomly signed out of my xbox, but not my microsoft account(at least on ms store). So I attempted to log in, which gave me various errors. Eventually I decided to reinstall xbox, but going back to the ms store also gave more errors, so I logged out as a whole, restarted my pc, then logged back into ms store with my ms account. I was able to reinstall xbox, but couldn't log in.
I had the app on my phone, still with the same old account, and decided to check if I had the same problem there, which I did. On my phone however, I was able to log in(kinda), but as I logged in, using all the same previous information as was on my one and only microsoft account, a new xbox account was created, instead of it logging me back into my previous one. I was able to look up my gamertag and see my account had not been deleted, but I cant log into it as every attempt to access it using my (ONLY) microsoft account results in me being sent to the new account instead. I only have xbox on my pc and phone, both of which I have had and used for years before this problem started last week. Help please.