Emails will be automatically linked to the contacts related to that email address in Salesmate. If this contact has only one deal open, the email will be attached automatically. If the contact has more than one deal open, the system can’t know which deal the email is supposed to be linked to. You need to choose which deal to link to from the Salesmate Mailbox.
You can choose the way an email links to the deal from My Account > Email Settings under the "Automatic linking to deals" heading.