Follow the below steps to migrate IMAP to Office 365
Go to Office365.com and sign in with Admin credentials.
Now, navigate to Setup in the menu and select Data Migration.
On clicking Data Migration, the “Select your data service” dashboard will appear on the screen. If your email provider is listed in it, then select it.
After selecting the email provider, you’ll be redirected to select users.
Select the users that you want to migrate and fill the email alias & password.
Click “Start Migration” at the left corner of the wizard after entering the required information.
The migration status will be any of these: Starting – Queued – Syncing – Synced. When the status comes to Synced, click “Stop Migration” to finish the process. Once the process is complete, click “Close Connection.”
I hope these steps will be useful while IMAP migration to Office 365.