The answer is when you go and even buy a simple suit, you roam around multiple shops and then select what you like, and buy it as per your budget. Now apply same formula on car but this time more research as more money is involved.
1.What brand u like
2. Price
3. Model
4. Trim level
5. Options
5. Resale if you are planning to sell in few years.
6. Offers/ incentives
7. Lease or finance?
8. Insurance( how costly it is) it depends on your driving record as well but also on make and model to some extent.
9. Utilization? Drive to work. Or just weekend car?
10. Maintenance?