1. Preheat oven to 375°F. Butter a 9-by-13-inch baking dish and place on a baking sheet lined with foil.
2. Combine three cheeses in a large bowl. Sprinkle flour over and toss to coat. Arrange half of potatoes, overlapping, over bottom of baking dish. Season with 3/4 tsp. salt and 1/4 tsp. pepper. Dot with half of butter. Sprinkle half of cheese mixture on top. Cover with remaining potatoes and dot with remaining butter. Season with additional salt and pepper.
3. Bring milk to a boil over medium-high heat. Pour over potatoes. Cover dish with foil and bake until potatoes are tender, about 45 minutes. (Don't worry if mixture looks curdled at this point.) Remove foil, sprinkle remaining cheese mixture on top and bake, uncovered, until potatoes are very tender and top is golden brown and bubbling, about 45 minutes longer. Let stand for 10 minutes before serving.