Let's take two random half lines, and just stick them together, like this:
an army was fleeing into deep jungle
Two such half-lines, as they stand, are almost indistinguishable from prose. If we were writing free verse, that would not, perhaps, matter too much.
But what we are discussing is structured verse, not free verse, and it needs to have a clearly measured rhythm, and a pattern which creates a kind of momentum as the poem is read aloud. And alliteration is the device used to measure out this rhythm.
What is alliteration?
Essentially, alliteration is repetition of sounds that start important syllables -- typically, consonants.
For example, we could change the first half line above to make it alliterate, like this:
an army was driven into deep jungle
The alliterating consonant is D. The repetition of this consonant at the start of driven and deep ties the two half lines together, increases emphasis on these two key words, and builds a stronger rhythm.
By the way, we would still get alliteration if we did it like this:
an army was driven
into the Outback
In this case, 'army' and 'outback' are the important alliterating words. They alliterate precisely because they both start with vowels.