Why do sidewalks have cracks in them? Why not one long strip of concrete? Why have sidewalks come in sections?
The answer: expansion.
When a substance heats up it has a tendency to expand. That's because the molecules that make it up have a greater average kinetic energy, or in other words, they're all jostling and bumping into each other.
Think of it like a room full of people. When they're all standing still, they take up less space than when everyone is dancing. Individual parts bumping and pushing cause the whole to expand.
Having sidewalks built in sections allows them to expand and contract a little bit on hot or cold days. If the whole thing were attached, it would buckle and break. Engineers have to take this fundamental property of matter into account when building everything from bridges to buildings.