I have a similar issue.
I was using Word 365 (the latest, with auto update on), on a Mac with 12.2.1.
I would edit a Word doc that is on a USB drive, make changes, hit save, and it gave an error box that said something like it could not save because the file was being used by another process. Then, at the top of the screen, in the blue bar, the file name would change to ~WRD000.docx most of the time. Sometimes it would be another file name that started with ~. The only way to save my document was to change the file name, or save it to the Mac's local drive, like the desktop or some other local folder.
I engaged MS support on this issue yesterday morning. I spent 2 hours chatting with 1st level support, doing standard troubleshooting, like uninstall, reinstall, cleaning normal.dot, stuff like that.
Then they put me through to 2nd level support. I spent another 2+ hours chatting with them. The only option for support is chat, and it takes so long because you wait a couple of minutes for a response each time, or more, sometimes 5, 15, and they have a method to share your screen so they can see it, but that takes a long time because you are chatting through each step they tell you to perform, each time waiting a long time for the next step.
One of the things 2nd level support did was to have me uninstall Word and install an older version of Word. I had the same issue with the older version. Also had me change some things with autosave. I had turned off all of the autosave/autorecover checkboxes under preferences before I even contacted MS, because I suspected that it was the problem. And that didn't fix the issue.
So total time chatting with MS yesterday about this was over 4 hours, at which point the 2nd level rep suggested we come back to it tomorrow, and said their tool for screen sharing was not working. I agreed to come back to it tomorrow, which is now today. Then the rep said she could meet between 10PM and midnight. I said that won't work because I go to bed at 9 or 10. She said, well that's my schedule. I said that it is not acceptable to tell someone that you can only support them at times they sleep, in the night time. She then said how about tomorrow afternoon? I said OK. She said look for an email from me with a meeting time. No email came.
I now have an older version of Word installed, autosave options off and whatever else we changed that I can't remember, and the same issue.
To work on documents, I need to move them to my local drive, edit and save them, and then move them back to my external drive, which is my primary storage location. I use an external drive to save all of my files so that my Mac does not get full and only has OS and apps.
It was noted above that cloud storage was used by the others with this issue. I DO NOT use cloud storage.
The answer given above does not solve my issue. Just seems to try to explain it a little, but does not solve the issue of trying to edit documents on anything but the desktop.