Preheat oven to 400 degrees F. Cut each puff pastry sheet into 4 equal squares (about 5" wide), then cover and place in refrigerator until later.
Add butter to a medium saucepan and heat over MED heat. Add onion and cook 3 minutes, until softened. Add flour and whisk to combine until mixture looks like wet lumpy sand. Cook about 1 minute, whisking often.
Pour in milk, in thirds, whisking well to combine after each addition to ensure no lumps remain. Continue whisking often as mixture cooks, about 5-7 minutes. Mixture will thicken considerably and should coat the back of a spoon.
Turn off heat and add ham and spinach. Add in 1 cup of the gruyere cheese and stir to melt the cheese into the sauce. Season with salt and pepper, to taste, and ground nutmeg.
Line baking sheet with parchment paper and place puff pastry squares on the sheet (if your baking sheet isn't large enough, 2 baking sheets may be needed).
Spoon 1 1/2 Tbsp of the cream sauce mixture into the center of a puff pastry square. Sprinkle with a bit of the remaining gruyere cheese, then fold all four corners of the puff pastry in towards the center, but not touching. Repeat with remaining puff pastry squares.
Whisk egg with the 1 Tbsp water to make an egg wash. Brush over the puff pastry and bake for 20 minutes, until golden brown.
Serve garnished with fresh parley if desired.