01 - Preheat the oven to 400°F.
02 - In a large baking dish, combine cherry tomatoes, garlic, red onion (if using), olive oil, oregano, red pepper flakes, salt, and pepper. Toss thoroughly to coat evenly.
03 - Create a space in the center of the dish and place the block of feta cheese. Drizzle additional olive oil over the feta.
04 - Roast for 30–35 minutes until tomatoes burst and release their juices, and the feta becomes golden and soft.
05 - While the feta mixture roasts, cook pasta in a large pot of salted boiling water until al dente according to package directions. Reserve ½ cup pasta water before draining.
06 - Remove the baking dish from the oven. Using a fork or spoon, mash and mix the softened feta and roasted tomatoes together until a creamy sauce forms.
07 - Add the drained pasta and most of the basil to the baking dish. Toss everything together, adding reserved pasta water as needed to achieve desired sauce consistency. Serve immediately, garnished with additional basil and freshly ground black pepper.