If you’re using two-factor authentication with your iCloud account (and you should), log into your iCloud account and create an app-specific password.
Now, please follow the below mentioned steps to add an iCloud account in Canary for macOS:
1) Open Canary.
2) In the system menu bar, open the Canary Mail menu.
3) Click Add Account.
4) Click on iCloud.
5) Enter your iCloud e-mail address with iCloud.com as the suffix.
6) Enter the app-specific password you created for Canary.
7) Enter an arbitrary name by which Canary will refer to your iCloud account.
8) Enter your name as you would like it to appear in the From header in outgoing messages.
Canary will automatically configure iCloud server settings for you, but should you ever need this information, you can find it in this Apple support article: