The state of matter you are describing is liquid. In liquids, the particles are closely packed together, but unlike solids, they are not fixed in a rigid structure. This allows them to slide past one another, which gives liquids the ability to flow and take the shape of their container.
In contrast, in solids, particles are tightly packed and maintain a fixed position, while in gases, particles are far apart and move freely without touching each other most of the time. Therefore, when the particles are close together and can move around easily, we identify that state as liquid.