Boil a large pot of salted water. Add the spaghetti and cook according to package instructions until al dente. Reserve 1 cup of pasta water, then drain the spaghetti.
In a large skillet, heat the olive oil over medium heat. Add the sliced garlic and red pepper flakes. Sauté for 2-3 minutes until the garlic is fragrant but not browned.
Add the halved cherry tomatoes to the skillet. Cook for about 5-7 minutes until the tomatoes start to break down and release their juices.
Stir in the fresh spinach and cook until wilted, about 1-2 minutes.
Add the drained spaghetti to the skillet, along with the reserved pasta water, and toss everything together.
Mix in the grated Parmesan cheese and lemon zest, then season with salt and pepper to taste. Toss until well coated.
Serve the pasta hot, garnished with fresh basil leaves.