Nerves from all over the body run to the spinal cord, which is the first main meeting point for the nervous system. In the spinal cord, you might imagine a series of gates into which messages about pain arrive from all over the body.
This is a link to a worksheet that helps explore ways to open and close the gates that let the pain messages through.