One form of clay is kaolinite. It consists of silicate (beige and red atoms) and aluminate (grey and red atoms).
Two layers are shown. Water molecules between the layers allow the two parts to slide past one another.
Firing the clay dehydrates it, and the layers become permanently bonded.