Combine the potatoes, onion, thyme, and 2 cups of the milk in a deep, wide skillet. Bring to a simmer over medium heat. Cover the skillet, and cook the potatoes until they are almost tender, 10 to 12 minutes. Uncover the skillet, and cook until the potatoes are fork-tender, 3 to 4 minutes longer. Season with ½ teaspoon of the salt and ¼ teaspoon of the pepper and set them aside.
Heat the oven to 350ºF. In a large bowl, whisk together the eggs and remaining 3 cups of milk, ½ teaspoon of salt, and ¼ teaspoon of pepper.
Line the bottom of a shallow 4-quart baking dish (such as a 15- by 10-inch dish) with 6 slices of the bread. Pour on just enough egg mixture to cover the bread, spreading it out to coat the slices completely. Layer the spinach evenly over the top, and spread the reserved potatoes evenly over the spinach. Sprinkle with half of the cheese; then layer with the remaining 6 slices of bread. Pour the remaining egg mixture over the top, pushing on the bread to saturate it. Sprinkle on the remaining cheese. (At this point, you may cover the dish and refrigerate it overnight if desired.)
Bake, uncovered, until the eggs are set and the cheese is lightly browned on top, 40 to 50 minutes.
Tip: For a touch of red, add 1 cup of chopped red bell pepper to the potatoes after you uncover the skillet.