When is it necessary to cover food with aluminum foil during baking/roasting?
If it calls for tightly wrapping it, they're trying for steam.  More than likely, they're just trying to shield the top from radiant energy, so the top doesn't brown before the whole thing is cooked through.

If you're ever baking a cake, and it's starting to brown, but a toothpick is still coming out wet, I'll move it to a lower rack, and put a sheet pan on the rack above, to keep it from browning much further, but not seal it in such a way that it would steam the cake.