To resign a game is to acknowledge that your opponent has reached a position so strong that only through gross mistakes would he/she lose. It is also a mark of respect because it assumes your opponent will not in fact make such mistakes.
Why do chess players resign?
There are two main reasons- to respect the oponent and to save time (when masters resign, it is in a hopelessly lost position). On the contrary there is some dignity in resigning when the loss is obvious. It saves time and effort for both sides, and I don't think masters really care about attaining a checkmate anyway.
Is it rude to resign in chess?
Chess coaches regularly instruct beginners to never give up and always play out the game to checkmate. “No one ever wins by resigning,” they say. Although this point may be true, sometimes a loss is inevitable, and wasting your opponent's time when you both know you're doomed is just plain rude.