Is it possible to deploy a single Exchange server for the 4 sites located at one of the sites?
You could let AD accounts located on domain B , C, D, but Exchange mailboxes hosted on domain A. This type of mailbox is called Linked Mailbox. But we don't know whether there exist issue with your SQL/File servers, if your File server needed to use Exchange function(About this one, I would suggest you have a test before migration).
By the way, there doesn't exist an official tool to migrate mailboxes from IMAP mail server to Exchange on-premises so far(Only supported to migrate to Exchange online). So, you may need to migrate mailboxes data with Outlook(Export and Import PST), or other ways.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.