In a recent Office 365 migration from On-premise exchange to Office 365,
everything was fine except for the Android Activesync setup. In fact, we were
trying all sorts of different settings and finally found this one which worked
in all the android devices.

Go to Settings / Accounts & Sync

Click on "Add Account", select "Corporate"

You can enter your email and password

For the "Domain\Username" you need to enter the full email address
with a "\" in front (eg. \someone@mydomain.com)

Next, you need to change the server to m.outlook.com

Click Next and you should be almost all set.

You will get a new window popup warning about allowing permissions to the
device administrator. Basically, an Office 365 admin can remotely wipe your
phone, but you won’t be able to sync your calendars if you don’t accept
this.