The size of the sensor is equally to number of pixels times the area of one pixel. So increasing the number of pixels clearly has an effect on the size, but so does the size of each pixel.
The smallest sensor pixel in conventional photography you can have will be limited by the diffraction limit of the lens that you use, which depending on the lens is usually somewhere around 0.5 to 1 micron. There is little point making the sensors smaller than this since it will not be able to resolve any changes.
The size of the sensor has two main effects on the final image captured. Smaller pixels capture fewer photons so the signal to noise ratio goes down. The ability to capture images in poor lighting is therefore degraded. The other effect is more artistic. Larger sensors have a narrower depth of field, meaning objects can go out of focus.
These two effects make it desirable to have larger sensors. To ensure a reasonable image quality the larger sensor is going to require a larger lens to cover its area. (Larger lenses also have more light gathering capabilities and so potentially produce better images.)
In summary, the larger the camera, the easier its to make higher quality images, but this has to balanced by the desire to have a small compact camera that fits inside a phone for example.