Cropping is the act of excluding elements from an image frame. It can either be done in camera or in post production.
In-camera cropping involves the decision to omit distracting aspects of a scene. Not everything will be able to be dealt with in-camera however, and when, for instance, the photographer didn't have a long enough lens to be as selective as they'd have liked with their in-camera cropping, pixels can easily be cropped away.
The downside to this is that you are actually losing resolution when you crop pixels in post, and if you crop heavily into an image you can severely limit print size at an acceptable quality level.
In addition to removing distractions, cropping in post can be done to change an image's aspect ratio. One reason to do this would be to change the aspect ration in order to print in a specific size.