Preheat oven to 400°F (200°C). In a 9x13-inch baking dish, place the feta block in the center. Scatter cherry tomatoes and smashed garlic cloves around the feta. Drizzle everything evenly with olive oil, then sprinkle oregano, red pepper flakes (if using), salt, and black pepper. Gently toss the tomatoes to coat without disturbing the feta.
Bake for 30 minutes, until the tomatoes have burst and softened, and the feta is soft and lightly golden on the edges. The oil should be fragrant and slightly bubbling.
Meanwhile, bring a large pot of generously salted water to a boil. Cook the rigatoni according to package directions until al dente. Before draining, reserve 1/2 cup of the starchy pasta water. Drain the pasta and set aside.
Remove the baking dish from the oven. Using a fork, immediately smash the softened garlic cloves and stir the melted feta and burst tomatoes together until a creamy, cohesive sauce forms. Add the drained pasta and toss to coat, adding a splash of reserved pasta water at a time until the sauce reaches a silky, clingy consistency.
Fold in the torn basil leaves. Transfer to a serving bowl or plate directly from the dish. Garnish with additional basil and a sprinkle of Parmesan, if using. Serve immediately.