Trench warfare
Armies used trench warfare because it gave soldiers cover while defending themselves against attack. It also gave soldiers bunks to sleep in, although the bunks were very unclean and uncomfortable.