Typical mail is handled with sendmail, a highly customizable mail exchange server.
It will come automatically installed so that you can send mail from the local machine, but you may need to do some tweeking for your situation. Configuring sendmail is done with the m4 utility and it will require a bit of learning on your part to get it right. In order to use the m4 utility you must create your own .mc file. This file will specify some settings and add features to your sendmail configuration. Here are a few options from my .mc file.