I want to send discount coupon code if Customer places his first order.
Discount coupon is required to be sent with thank you mail.
You can take advantage of our Follow Up Email extension that is able to automatically contact customers according multiple rules and conditions. You can even create chains of emails, e.g. offering 10%, 15% and 20% discounts one by one in order to bring customers back eventually. And much more.
Follow Up Email for Magento 1 - https://goo.gl/KHu4F9
Follow Up Email for Magento 2 - https://goo.gl/ikSD9s
Followup emails extension for Magento is built for this purpose, you can send reminders to customers via email, share whatever information you need, such as coupons, gifts, offers etc.