Arrange a single layer of beets in the casserole. Brush lightly with olive oil, then sprinkle with a bit of cheese, a little thyme, and a pinch of nutmeg, then salt and pepper. Continue to layer the rest of the ingredients (only sprinkle salt, pepper,and nutmeg on the 1st layer), pressing down lightly as you go. Bake until gratin is bubbling, the beets are tender, and the cheese golden, about 45 minutes. Allow to rest 5 minutes before serving.