Heat the oven. Preheat to 375°F (190°C).
Lightly oil a 9x13-inch baking dish or similar casserole pan.
Boil the pasta. Bring a large pot of salted water to a boil. Cook ziti until just shy of al dente, about 1–2 minutes less than the package suggests. Drain well.
Warm the sauce. In a large skillet, heat olive oil over medium.
Add minced garlic and cook 30 seconds until fragrant. Pour in marinara, season with a pinch of salt, pepper, and optional herbs or red pepper flakes. Let it gently simmer 3–5 minutes.
Mix the cheeses. In a bowl, stir ricotta with half the mozzarella and half the Parmesan.
Season with a pinch of salt and pepper. This keeps the filling creamy and flavorful.
Combine pasta and sauce. Add the drained ziti to the skillet of warm sauce. Toss until every piece is coated.
If your skillet is small, do this in the pot you used for pasta.
Layer in the baking dish. Spoon half the sauced pasta into the dish. Dollop and spread the ricotta mixture over the top in an even layer. Add the remaining pasta.
Finish with the rest of the mozzarella and Parmesan.
Bake. Cover loosely with foil and bake for 15 minutes. Remove foil and bake another 10–15 minutes, until the top is melted and lightly browned at the edges.
Rest and serve. Let it sit 5–10 minutes so it sets. This makes slicing easier and keeps the layers intact.
Serve warm.