How to delete emails that are, say, 3 years or older?

Like 3-4 years ago I went through this thing where I refused to delete any emails, including unread ones. Now on my iphone I have an annoying notification that says I have 1, 492 unread messages.

Is there any way for me to delete like really old messages while keeping my emails that are still relatively new?

Yes

Since early June All of the emails are on one page… It may not look like it, but if you scroll down thru your list of emails it will eventually get to the bottom. To delete emails at this time just place a check mark in the box to the left of SORT BY DATE, which then places a check mark in All of the boxes to the left of your emails. If you want to save some you will have to scroll down thru your emails and remove the check mark to the left of the one you want to save… You can remove the check mark by clicking on it…
+++…
I have now seen where placing a check mark in the box left of SORT BY DATE does not always place a check mark in the boxes to the left of All emails… Occasionally it does, but sometimes it is 25 and sometimes 50 emails.Sometimes it makes a difference on where you are in the long list of emails… Sometimes you have to scroll to the end of your email list before placing a check mark left of SORT BY DATE to place a check mark left of all emails… You will have to experiment.
+++…
This is another very good way to delete some emails… I have to give credit to this answer to HELLO WORLD
Click the box next to the first message you want to delete. Hold down the Shift key and click the box next to the last message you want to delete. All messages in between will be highlighted and can be deleted at once.
+++…
The quickest way I have found to scroll is to place your pointer at the bottom of the scroll bar on the far, right side just above the down arrow and click once to move it one page at a time or hold down the pointer with the left click of your mouse and the list will move down VERY rapidly. You can also, in this area, just click rapidly on your mouse to do the same thing.

You have the option of clicking on the TRASH can just to right of the date for a particular email when your inbox is displayed

The only other option is to individually click on the box to the left of each email you want to delete. For both options, except for the TRASH can… When done, is to go above and click on DELETE.
+++…

This link explains the new method…

http://www.ymailblog.com/blog/2013/06/qu…
I credit ECHNIPSOS (sp) for this link.
+++…
If you want to delete only emails from a particular sender… Do this

Enter the senders name in your SEARCH MAIL box on your email page… This will bring up all the messages from this person. The location in the NEW format is in the bottom line of the of the email. Click on DELETE at the top… The location will change to TRASH… Go to you trash folder and empty it… They will be gone…
+++…
This link is a great tutorial for how to handle almost everything in the Newest version. If you can't find it just enter your question in the search bar.