All kinds of digital cameras and smart phones that are able to capture photos, store them as elements called pixels. A Megapixel equals one million of those pixels and they all make up a digital picture. The more pixels, and thus the higher the number of Megapixels, the better is the resolution of the image. This also directly relates to the quality of an image.
Of course, Megapixels aren't the only factor determining the quality of an image. Thus, the camera with the higher amount of Megapixels isn't automatically the one that takes the better pictures.