I know after you get a phd you get the title of doctor, but how do you become a professor?
This is the usual process for math/science:
1) Get your PhD.
1a) While in graduate school get published, do some good teaching and make lots of connections.
2) Upon completion of your PhD go to a post-doctoral position for a year or two. Here you concentrate on research and try to get some solid publication under your belt.
3) At this point you usually apply for a professorship. You usually start out non-tenured and work your way up.
Expect to spend more than a year or two as a postdoc. More like 3 or 4 years. It can be more than that if there aren't many positions available, though at that point, it's best to try for a research track faculty appointment.
You can then get either a research-track appointment, or a tenure-track appointment. Research-track doesn't require teaching, but does require independent research funding and doesn't lead to tenure. Tenure-track requires teaching in addition to research, and depending on your university/department rules, you'll come up for tenure review in 4 to 7 years. When you get tenure, you'll also get promoted from assistant to associate professor. There's another review process later on to be promoted from associate professor to full professor. A handful of those who are outstanding in their field will be promoted later in their career to professor II.
Generally, to get a tenure-track faculty appointment, you need to demonstrate a strong publication record both in graduate school and during your postdoc, evidence of effective teaching ability, and strong potential to obtain extramural funding (if you're able to apply for, and obtain, a postdoctoral training grant, this will help greatly when it is time to apply for a faculty appointment).
Separate names with a comma.