When setting up an iCloud mail with AirMail it uses the outdated icloud.com domain.
Apple has officially moved its mailing services to me.com and the latest IMAP setup can be found on the official apple page. the default automated setup will fail.
https://support.apple.com/en-us/102525