In my research, it may be related to the discovery system mailbox. So please check if it exists in "Users" OU.
If existing, please check the attribute "homeMDB", and ensure that it has a valid value the same as another system mailbox.
Or run "Get-Mailbox -Filter { RecipientTypeDetails -eq "DiscoveryMailbox
"} | fl name, database" to see if it returns any error.
If anything is wrong, you could try to delete this system database and recreate it by running "Setup.exe /IAcceptExchangeServerLicenseTerms /PrepareAD", then re-run the setup wizard and check if the issue persists.
You could refer to this similar case and this blog, Setup a New Exchange 2019 Server.