Emails do not go out from the website.

We are having a problem with sending out emails. We have an application server that runs a web application. The web application requires to send out emails.
For this purpose we installed an email server (PostFix) on the same machine. When the web application sends out emails to OTHER domains using local host, as the email relay server, it works. However, when we try to send emails that correspond to the same domain name as the application, we get the following error:
