Prep: Preheat the oven to 425F. Set two baking sheets aside and bring a large pot of salted water to a boil for the pasta.
Roast the Vegetables: Cut the top 1/4” off of the head of garlic to expose most of the cloves. Place on a sheet of aluminum foil, then drizzle with oil and wrap it up to seal it tightly. Add the butternut squash and shallots to the baking sheet and drizzle with oil, salt, and pepper to taste. Use your hands to toss until evenly coated, then spread the vegetables out evenly on the baking sheet. Add the foil-wrapped garlic to the baking sheet as well. Bake for 30 minutes, flipping the squash and shallots halfway through cooking.
Cook the Pasta: In the meantime, add the pasta shells to the boiling pot of water and cook following the pre-boil or stuffed shell instructions, stirring occasionally. If the package does not have instructions, cut the cooking time of the pasta in half, then add two minutes. Drain and rinse with cold water, then spread the shells across a baking sheet in a single layer to prevent sticking.
Make the Ricotta:add the tofu, cashews, nutritional yeast, garlic, lemon juice, and salt to a food processor with the S-blade attached. Process for 45 to 60 seconds, scraping the sides as necessary, until a smooth texture forms. Set aside.
Blend the Sauce: add only ⅓ (roughly ½ cup; 75 g) of the roasted butternut squash to a blender along with the roasted shallots. Carefully remove the garlic bulb from the tin foil and squeeze the cloves into the blender as well. Add the cashews, oil (if using), cinnamon, black pepper, broth, and milk to the blender. Blend on high for 45 to 60 seconds, or until a smooth sauce forms. Taste the sauce and season with additional salt or pepper if necessary.
Make the filling: place the prepared ricotta in a large mixing bowl and add in the remaining roasted butternut squash, spinach, rosemary, salt, and black pepper to taste. Mix well with a spatula until everything is evenly incorporated.
Stuff the shells: Pour 2 cups of sauce in the bottom of the baking dish. Fill each cooked shell with ~1 tablespoon of filling, then place in the baking dish. Repeat with the remaining shells, then pour the remaining sauce on top. Sprinkle the cheese over the tops of the shells, if using.
Bake: Bake in the top rack of the oven for 20-25 (?) minutes, until the sauce is bubbly and cheese has melted.