The position of president pro tempore of the US Senate exists because the Constitution mandates it. The Constitution required that such a position would be created because the official president of the Senate might often not be able to preside at meetings of that body.
The official president of the Senate is, of course, the Vice President of the United States. Although he (or someday she) is the official President of the Senate, he rarely actually presides. The Vice President is a member of the executive branch and as such does not really participate in the business of the Senate. Ever since the earliest days of the Constitution, the vice president has only voted when a vote of the rest of the Senate ends up tied.
With the official president of the Senate likely to be absent so much, it was seen as necessary to create an official who would preside over the Senate most of the time. That person is the president pro tem. This position is, however, now almost completely honorary and carries with it essentially no power. It is typically given to the longest-serving member of the majority party in the Senate.