Yep, it's a bit of a mess.
Thankfully, email protocols take the basic approach that it's none of your business whether or not I read anything you sent me.
Depending on your email setup, there may be a couple of bounces between the server your PHP script sits on and the one which attempts to contact the outside world with your mail. This is the server wich your MTA (Mail Transport Agent) sits on.
If something bad is brought to the attention of the MTA, it will be recorded in the MTA's logs. For example, if the domain name doesn't resolve, or the recipient's mail server can't be found, or the recipient's mail server doesn't respond, or the recipient's mail server rejects the mail, these responses will appear in the logs.
You could write a script to process the logs and look for failed attempts, and generate a report based on that
However, this won't catch the situations such as the recipient's mail server accepting then binning the mail, or the mai falling foul of spam filters or other rules on the recipient's end. It might also report false positives. For example, the recipient's mails erver might be don for a few minutes just when you try to send the mail. In all likelihood, your server will retry the mail later and it will get through fine.
If processing the log file scares you (and it needn't) you could also make sure that you instead write a script to probe the mailbox from which you are sending the mails. Any bounces should also generate a "Sorry, couldn't do it" mail to that address, which your script could then find and deal with. In this case, you would need to ensure that any other systems you use to check that mail address don't delete the original mails form the server.
Not perfectly straight forward. not perfectly fool proof. But you can come up with something.