Theory:

Anaphora is one of the most commonly used rhetorical device. It is a type of repetition where a word or phrase is repeated at the beginning of a phrase, sentences, stanza, or a paragraph. It is also known as Repetitio.
Pronunciation Guide 
Anaphora-- Ana (as in analyse) -- pho (as in phone) -- ra (as in Dora)
Let us consider the poem "Your Space" by David Bates as an example.
Example:
Speak gently! – It is better far
     To rule by love, than fear
Speak gently – let not harsh words mar
     The good we might do here!
 
Speak gently! – Love doth whisper low
     The vows that true hearts bind;
And gently Friendship’s accents flow;
     Affection’s voice is kind.
 
Speak gently to the little child!
     Its love be sure to gain;
Teach it in accents soft and mild:-
     It may not long remain.
 
Speak gently to the young, for they
     Will have enough to bear –
Pass through this life as best they may,
     ‘T is full of anxious care!

Speak gently to the aged one,
      Grieve not the care-worn heart;
The sands of life are nearly run,
      Let such in peace depart!
 
Speak gently, kindly, to the poor;
      Let no harsh tone be heard;
They have enough they must endure,
     Without an unkind word!
 
Speak gently to the erring – know,
     They may have toiled in vain;
Perchance unkindness made them so;
     Oh, win them back again!
 
Speak gently! – He who gave his life
     To bend man’s stubborn will,
When elements were in fierce strife,
     Said to them, ‘Peace, be still.’
 
Speak gently! – ’tis a little thing
     Dropped in the heart’s deep well;
The good, the joy, which it may bring,
     Eternity shall tell.
The above poem is an example of anaphora because the phrase "speak gently" gets repeated at the beginning of each stanza.
 
The following example is an extract from a popular speech by Martin Luther King, Jr. The speech is known as "I have a Dream". It got its name from the anaphora "I have a dream". Interestingly, the popularity of speech can also be because of the repetition of the phrase.
Example:
I say to you today, my friends, so even though we face the difficulties of today and tomorrow, I still have a dream. It is a dream deeply rooted in the American dream.
I have a dream that one day this nation will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all men are created equal."
I have a dream that one day on the red hills of Georgia the sons of former slaves and the sons of former slave owners will be able to sit down together at the table of brotherhood.
I have a dream that one day even the state of Mississippi, a state sweltering with the heat of injustice, sweltering with the heat of oppression, will be transformed into an oasis of freedom and justice.
I have a dream that my four little children will one day live in a nation where they will not be judged by the color of their skin but by the content of their character.
Example of anaphora from the poem "Whatif":
Last night, while I lay thinking here,
Some Whatifs crawled inside my ear
And pranced and partied all night long
And sang their same old Whatif song:
Whatif I’m dumb in school?
Whatif they’ve closed the swimming-pool?
Whatif I get beat up?
Whatif there’s poison in my cup?
Whatif I start to cry?
Whatif I get sick and die?
Whatif I flunk that test?
Whatif green hair grows on my chest?
Whatif nobody likes me?
Whatif a bolt of lightning strikes me?
Whatif I don’t grow taller?
Whatif my head starts getting smaller?
Whatif the fish won’t bite?
Whatif the wind tears up my kite?
Whatif they start a war?
Whatif my parents get divorced?
Whatif the bus is late?
Whatif my teeth don’t grow in straight?
Whatif I tear my pants?
Whatif I never learn to dance?
Everything seems swell, and then
The night-time Whatif strikes again!
 
In this poem, the word "whatif" (highlighted in green) is used at the beginning of almost every new sentence.
 
Important!
NOTE!
But also note that the words "whatifin bold letters are not a case of anaphora. It is so because they appear NOT at the beginning. 
Reference:
State Council of Educational Research and Training (2019). Term-1 English Standard-6. The Crocodile - Lewis Carroll (pp. 99-100). Published by the Tamil Nadu Textbook and Educational Services Corporation.
 
State Council of Educational Research and Training (2019). Term-1 English Standard-7. Your Space by David Bates (pp. 70-72). Published by the Tamil Nadu Textbook and Educational Services Corporation.

National Council of Educational Research and Training (2006). Honeysuckle. Whatif (pp. 121-122). Published at the Publication Division by the Secretary, National Council of Educational Research and Training, Sri Aurobindo Marg, New Delhi.
 
https://www.history.com/topics/civil-rights-movement/i-have-a-dream-speech