For the past around the year capitalization changes on your username were impossible(seen on WEB-2181). And it was resolved yesterday as of posting this. But when I tried to change the capitalization of my microsoft migrated account username "hocuspocus", different capitalization would show as taken. This is proven to be possible in mojang account but not in microsoft accounts. In addition, when I tried to change the username through the API it gave me a 403 saying that the username was a duplicate, the exact error you would get if you tried to change the capitalization on a mojang account before the fix. I'm hoping this can be fixed as I was looking forward to changing my username capitalization.
Can confirm this still does not work for MSA (migrated) accounts.