I've managed to resolve the issue and was able to log back in again.
After some more poking around, I noticed e-mails from Office 365 were still sent to the original registration address. I looked up the user to which the e-mails were sent in AD, and tried logging in with that user. It turned out the user still had full admin rights.
So apparently, dirsync has replaced the renamed account of 'beheerder@ourdomain.onmicrosoft.com' and set the account back to the original one with the federated domain name.
Best regards,
Jelle Hillen