Preheat the oven to 350°F (175°C).
Bring a large pot of salted water to a boil and cook the penne according to package directions until al dente; drain and return to the pot.
Add the cooked chicken, marinara sauce, 1½ cups of the shredded mozzarella, and ½ cup of the Parmesan to the drained pasta; season with salt and black pepper and stir to combine.
In a medium skillet, melt the butter over medium heat, then add the minced garlic and panko; cook, stirring, for 3–4 minutes until the crumbs are toasted and fragrant. Remove from heat and let cool slightly.
Spray a 9×13-inch baking dish with nonstick spray. Transfer the pasta mixture to the dish and spread into an even layer.
Top the pasta with the remaining 1½ cups mozzarella. Stir the remaining ½ cup Parmesan into the toasted panko and sprinkle the mixture evenly over the cheese layer.
Cover the dish with a piece of foil sprayed with nonstick spray and bake for 30 minutes.
Remove the foil and bake an additional 5–10 minutes until the casserole is bubbly and the panko topping is golden brown.
Let cool a few minutes, garnish with chopped fresh basil if using, and serve.
Note: If you do not have cooked chicken, cut 2 boneless skinless chicken breasts into bite-size pieces and cook in a little olive oil until cooked through; season with salt and pepper before adding to the pasta.