At the bottom, click on the toggle button next to “Allow apps that use less secure sign in” so that the “ball” is on the right.
The change is effective immediately; You can dismiss any password prompts in Outlook and press the Send/Receive button to get your emails again.
When you still get prompted, it is best to close and restart Outlook. If you still get prompted then, retype your password in the dialog box and make sure to select the option: Save this password in your password list.
Method 2: Enable Two-Step Verification
If you do not wish to re-enable the above security setting, then you can enable Two-Step Verification as an alternative.
Once you have enabled Two-Step Verification for your Yahoo account, you must generate a special App Password.
Instead of using your regular password in Outlook, you must now use that special App Password when being prompted for your credentials.