The values are approximations of each piece's strength. The true, exact, "objective" value of each piece is unknown. For example, Fischer believed the bishop to be worth about 3.25, Kasparov back in the day thought it was about 3.15 (but he's recently changed his opinion to be closer to Fischer's). There are reasons for the hierarchy though, and why the approximations make sense:
1) First, it could be considered an axiom that a knight/bishop is roughly 3 times better than a pawn. There's no direct reason for this, it just seems to be the case. So a knight/bishop are roughly 3 points. Even though the bishop has longer range than the knight, it is limited to one colour complex, making them roughly equal.
2) Next, the rook. A good way to think about this piece is that it's like the bishop except can move on either colour square. For this reason, it's worth about 5 points. Not quite double the bishop, but clearly better.
3) Finally the queen. It's the rook and bishop combined into one piece. So instead of being worth 8 points, it's around 9. Since it unifies the strength of the rook and bishop into one force, it's generally considered slightly better than these two individual pieces.