Day 4.
So, restored the VM for osTicket to be rolled back, reconfigured, and deleted/recreated mailbox with Office365. All working again. So it turns out that something breaks Office 365 and/or osTicket if you try to use a subfolder of Inbox with a forward slash. eg. "INBOX/fetched" or whatever. Trying to use dot doesn't work. I can't see a way to put fetched emails into a subfolder of InBox, so will move on for now. Maybe it's a bug in osTicket, or when osTicket asks Office365, or whatever then ends up in the MariaDB/MySQL or something. Anyway it all goes pear-shaped from then on.
For now I will not worry, will stick with a folder called something like "InBox.osTicket" and maybe developers can look into this?
** So for now, I'd say don't use forward slash in your Fetched Emails move to folder setting. **
Leaving here for warning/info for others.