I have installed phpmailer module and it works fine. https://drupal.org/project/phpmailer
But it doesn't seem to have the option for DKIM. How can I set DKIM for the mails sent by phpmailer?
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.Sign up to join this community
Support for this it was requested over 2 years ago, and was moved to 7.x-3.x-dev branch, so it will not be possible in phpmailer for Drupal 6. The reason is that Drupal 6 will reach the end of its life soon, when Drupal 8 stable will be released. Thus, it will never be possible to set it in phpmailer for Drupal 6.
Anyway, enabling it at PHP level is a costly procedure. PHP is not really the best language for cryptography. As you can read here, configuring DKIM support at the MTA level makes all your server generated email for a given domain signed by default, and also off-loads the calculation burden to the system that's supposed to be optimized for it.
To make sure there is your MTA involved, you can use SMTP Authentication Support module. As you can see in it's issue queue it does not enable you to force DKIM from Drupal, but at least it ensures your mail server is sending mails, and does not interfere with mailserver's DKIM settings either.