There's only three components to look at for any piano you want to buy. Cosmetic (how it looks), function (how it plays), and tone (how it sounds).
What can be confusing for many piano buyers is that there is a wide spectrum of personal taste for each component.
New pianos- does it look the way you want to have it in your home. Pretty simple. It comes down to design and finish.
Used pianos- the condition of the outside of the piano can be indicative of the care the owner(s) took of the inside. It's possible that a raggedy outside has no correlation to the quality of the action or tuning history- but not likely. You can make the cosmetic decision without knowing anything about pianos.
For beginners, there is no way to know if the keys play in a way that you will be happy with when your "chops" become discerning. You should bring an accomplished player to try it out. They don't know what you will like either, but they can rate the function on response (quick or slow), depth (too deep or shallow), dynamic range (ease of playing soft or loud). Listen carefully for any non-piano noises such as buzzes or rattles. Also listen for "dead" notes. If there are any buzzes, rattles, or dead notes, there may be serious problems with the piano. Also, be sure to open the bottom board (above the pedals) to look for water lines and/or rust on the strings. Usually there are springs at the top of the bottom board that allow you to push up on to pull the board toward you.
This is a very personal component. Everyone has different pre-conceived idea of what they like in tone quality. It's extremely complex when you break tone down into what makes up the tone. But keep it simple. Score the pianos you listen to on a 0-10 scale. 0=muffled 10= bright. Only you know what you like. Tone can be softened a little if too bright- and can be brightened a little if too muffled.
New pianos are priced competitively. Price is not always a good indicator of quality. New pianos are historically marked up a lot. You should be able to negotiate a price well below list price.
The important thing to remember about used pianos is that there is no correlation between asking price and quality. The same model/brand used piano can be posted for $4000 or $400. Keep a log of the piano, model and price to give you a better idea of what they are actually worth.
Age of the piano becomes a factor only if it has a lot of "miles" on it. If the keys have a lot of side shake (should have very little) beware ! Also look inside. There are a lot of miles if the hammers have deep grooves where the hammer hit the strings. The impact packs the felt to become hard and typically causes the tone becomes painfully harsh.
While you have it open, make sure the pedals work and don't make squeaks- or others annoying noises. This is usually fixable, but can be expensive.