Preheat the oven to 350 F. Spray 2 6-cavity donut pans with nonstick spray, and set aside.
In a medium bowl, whisk together the flour, baking powder, baking soda, salt, cinnamon, and allspice.
In a large bowl, whisk together the brown sugar, vanilla extract, orange juice, ¼ cup melted butter, and egg until well combined.
Add the flour mixture into the bowl with the wet ingredients, and whisk to mix.
Add the shredded carrots to the batter and mix until just combined.
Spoon or pipe the donut batter into the prepared donut pans, filling each donut cavity about ¾ full.
Bake for 10-12 minutes, until the donuts bounce back when you touch them.
Cool donuts in the pans for 5 minutes, then transfer to a wire rack to finish cooling.
Meanwhile, make the glaze: Add the cream cheese to a medium bowl. Microwave for about 20 seconds until warm and soft.
Add the confectioners' sugar, 2 tablespoons melted butter, and milk to the bowl and whisk until smooth. If the glaze is too thick or dry, add another ½ teaspoon milk at a time until the glaze reaches your desired consistency.
Dip the cooled donuts into the glaze on one side, then top with chopped walnuts if desired.