Heat olive oil in a large deep nonstick skillet over medium heat. Add the sausage, breaking it apart with a wooden spoon, and cook until browned, about 5 minutes. Stir in the onion and garlic, cooking until they soften, roughly 2 minutes. Pour in the crushed tomatoes, add the basil, and season with salt and pepper to taste. Reduce heat to low, cover, and let simmer for 15 to 20 minutes.
While the sauce simmers, cut the butternut squash into 1/8-inch thick rounds using a spiralizer with a wide blade, a mandolin (use caution), or a sharp knife. Set aside.
Preheat your oven to 375°F (190°C).
In a medium bowl, mix together the ricotta, Parmesan, parsley, and egg until well combined.
Spread 3/4 cup of the sauce evenly over the bottom of a deep 9x12 casserole dish. Arrange 12 butternut rounds in a single layer atop the sauce. Spread 3/4 cup of the ricotta mixture over the squash, then sprinkle with 1 cup of mozzarella and pour over 1 cup of sauce. For the second layer, place 12 more butternut rounds, followed by 3/4 cup of the ricotta mixture, 1 cup of mozzarella, and 1 cup of sauce. For the third layer, lay the remaining 12 butternut slices, pour over 1 1/2 cups of sauce, and cover the dish with foil.
Bake the covered casserole for 30 minutes.
Remove the foil and continue baking for another 30 minutes to evaporate excess liquid. Sprinkle the remaining mozzarella on top and bake until the cheese melts and bubbles, about 5 minutes.
Allow the dish to rest for 5 to 10 minutes before slicing into 8 portions.