Preheat the oven to 400°F (200°C).
Bring a large pot of salted water to a boil and cook the rigatoni according to package directions until al dente.
Reserve 1/4 cup of the pasta cooking water, then drain the pasta in a colander.
Return the hot pasta to a large bowl and add the pesto and crushed tomatoes. Add some reserved pasta water as needed to create a slightly saucy coating without making the pasta watery; stir to combine.
Spray a 9x13-inch baking dish with nonstick spray. Spread half of the pasta into the dish and sprinkle with half of the shredded mozzarella.
Add the remaining pasta, top with the remaining mozzarella, and spread evenly.
Bake for about 20 minutes, or until the cheese is melted and bubbly.
Remove from the oven and serve garnished with chopped fresh basil.