Go to the options of iPhone's Settings.
Choose the options of Mail, then select the options of Accounts.
Then Enter the options of the Yahoo! under the option of Add Account.
Enter your email address and Enter the button of Next. In the same way, enter your password and and Enter the button of Next.
Move the options of drop-down menu left-side to the corresponding Mail, Contacts, Calendars, or Notes option will now allow you to choose which details to download to your iPhone.
Enter the button of Save after configured the settings of ATT email account.
So, these are the workarounds that will assist you in resolving the ATT email not working on iPhone problem.
See Also this post:- https://www.datarecovo.com/att-net-email-login/
https://www.datarecovo.com/how-to-set-up-att-email-on-iphone/