Mirkwood is a dangerous and wicked place, and you can’t light a fire because you will be watched by its inhabitants—including giant spiders.
The “way through Mirkwood is dark, dangerous and difficult.” The water is not safe to drink or even touch, and there is no food. The nights are even worse, being cold and full of creatures.
In addition, since the forest is enchanted with darkness, the animals in it are violent and deadly.
Although it was not yet very cold, they tried lighting watch-fires at night, but they soon gave that up. It seemed to bring hundreds and hundreds of eyes all round them… (ch 8)
The fires also attract moths and bats. As the adventurers soon learn, some of those eyes belong to giant spiders. Before meeting them, the adventurers find it difficult to find enough food or water to drink, and eventually they try to go toward the fire and get captured by the spiders.