Liquids can flow as they have less intermolecular force of attraction in comparison with solids. Hence, the layers of molecules can slide over one another showing moderate fluidity.
Whereas solids have highest inter-molecular forces of attraction due to which there is negligible inter-atomic movements. Hence, the layers of molecules can be stacked one upon the other showing tight molecular arrangement.
Therefore, liquids can flow but solids cannot flow.