When we say that the space we live in has three dimensions, what does that mean?
When we describe the size of an object, or of a space like a room, we use three numbers: the height, the width and the depth. The height, width and depth of a room are numbers that can vary independently from one another. That’s one way to see that space is three dimensional. Another way is that we need three numbers to exactly locate ourselves on the Earth: longitude, latitude and elevation above sea level. That’s another argument for space being three-dimensional. That’s what we see.
When mathematicians or physicists talk about dimensions, they mean the number of independent coordinates needed to specify any point in a given space. The tradition is to label these three coordinates (x,y,z), with z usually denoting the up direction or the direction of height.
One of the big discoveries of early classical physics was the similarity between the forces of gravity and electrostatics. The gravitational force between two planets and the electrostatic force between two electric charges were both observed to vary as the inverse square of the distance between the two objects. So if r is your distance from the center of a planet, then the gravitational force of that planet on you will vary like r-2. If you go twice as far away, the force will only be one fourth as strong.
But the number of coordinates in a mathematical equation is easy to increase on paper. When the gravitational and electrostatic equations are solved in a space with D dimensions, then the force varies with distance like r1-D. (Notice this gives the right answer when D=3.)
This gives physicists an interesting way to do fine measurements of the numbers of dimensions of space. They can look at the gravitational force and put quantitative limits on any funny behavior that would come from possible extra dimensions.
If three space dimensions is consistent with current gravitational physics and interior decorating, then why look more closely at the force law? Because there are ways that extra dimensions of space can become undetectable or at least very difficult to detect by our world, so we can eat our cake and hide it, too, so to speak