Solid matter (such as sand) that is made up of many individual small particles is called a granular material, and the individual particles are called grains. Granular materials can range in size from small powders such as sugar and flour to large objects such as rocks and boulders. Note that the word "grain" doesn't just refer to things you'd traditionally call grains, such as sand or rice; it can be any object or particle in a granular material.
For a granular material to behave like a liquid there must be many, many grains close together. For example, a single boulder rolling down a hill is not acting like a liquid; but thousands of rocks, boulders and dirt particles flowing down a hill during a landslide do behave like a liquid. When granular materials flow like a liquid, it's called granular flow.