From my old Mac I exported the mailbox (took just one to test) to a folder in Dropbox. Looks fine to me.
On my new Mac went to Mail/Archive and chose Import mailboxes, then followed the instruction, chose Apple Mail, and chose the file in the Dropbox folder, worked fine, and a message came up saying the the imported mailbox is in a mailbox named Import in the sidebar. All looks fine so far but I have not found any mailbox named Import. (I use Mail ver 16 on bot the computers).
Further info: I looked up Apple's instructions before trying and have, as far as I know, followed them. I have tried with 3 different mailboxes with the same result.