Let us change the resolution to 300 pixels per inch, a more typical choice for printing an 8x10 print on a good quality desktop ink jet printer.
Resolution is set by the image editor, YOU, in Photoshop. Resolution describes how many pixels there will be PER INCH.
Replace 72 ppi by 300, and the new dimensions become 9.707 by 14.56. The image is smaller in size in inches, but has a higher resolution in pixels per inch, but still has the same exact pixels it began with.
Be sure to UNCHECK the Resample Image box ( which is checked in the first version seen above ) so you will not create or remove any pixels. You will now have exactly the pixels you started with. NO more, NO less. But the image size IN INCHES changes automatically.
Historically, 72 pixels per inch is standard resolution for web based images, while images destined for printing need resolutions in the order of 180- 360 pixels per inch.
Counter-intuitively, larger prints can be printed at much lower pixels per inch ( at only ~150 pixels per inch) because they are usually viewed from a greater distance - such as a billboard along a highway viewed at 100 feet versus an 8 by 10 inch print viewed at 8 inches.
The original image must have enough TOTAL pixels to achieve a satisfactory pixels per inch, to allow an image to be displayed in a print or on a monitor with appropriate sharpness and detail.
Too few pixels per inch will result in a loss of sharpness and detail.