Toss the cherry tomatoes and olive oil with 1/4 teaspoon of salt and several grinds of black pepper in a medium bowl until combined.
Pour into a 2 1/2 to 3-quart baking dish. Place the feta in the center of the tomatoes, then season with a pinch of black pepper.
Bake until the tomatoes have burst and the feta has softened, about 30 minutes.
Raise the heat to 450 degrees F, then continue to cook until the tomatoes and feta are golden brown, 10 to 15 minutes more.
Meanwhile, bring a large pot of generously salted water to a boil over high heat.
Add the pasta and cook until al dente, about 13 minutes. Reserve 1/2 cup of cooking water, then drain well.
As soon as the tomatoes and feta come out of the oven, stir in the garlic and red pepper flakes.
Use the back of a spoon to smash the tomatoes and feta into a smooth and creamy sauce
Add the pasta and half of the basil until evenly coated. Add some pasta water, a couple tablespoons at a time, if the sauce becomes too thick.
Taste and adjust the seasoning with salt and pepper. Top with the remaining basil and a pinch of sea salt for serving.