Jesus, being God, could not have forsaken himself, nor is it possible for His human and divine natures to be separated with one talking to the other, so this is not a lament. The Jews of Jesus' time, not having bound copies of the Old Testament to carry around with them, studied the Word of God and committed it to memory. The devout Jew would pray the Psalms and other Scriptures from memory as he worked and traveled. The sacred writers of the New Testament knew that if they included a key phrase from a Psalm or other sacred writing, the entire context would be brought to the mind of the listener (reader). If I were to say "I pledge allegiance to the flag," any American hearer would immediately recall the rest of the pledge. "My God, My God, Why have you forsaken me?" are the opening words of Psalm 22 and Jesus, in praying this particular Psalm, was calling to the minds of all who heard Him the context of this Psalm; which foretold, in graphic detail, all that was happening to Him. It was a final reminder that He was the promised Messiah.
Psalms
Chapter 221
1 2 For the leader; according to "The deer of the dawn." A psalm of David. 2 My God, my God, why have you abandoned me? Why so far from my call for help, from my cries of anguish? 3 My God, I call by day, but you do not answer; by night, but I have no relief. 4 Yet you are enthroned as the Holy One; you are the glory of Israel. 5 In you our ancestors trusted; they trusted and you rescued them. 6 To you they cried out and they escaped; in you they trusted and were not disappointed. 7
3 But I am a worm, hardly human, scorned by everyone, despised by the people. 8 All who see me mock me; they curl their lips and jeer; they shake their heads at me: 9 "You relied on the LORD--let him deliver you; if he loves you, let him rescue you." 10 Yet you drew me forth from the womb, made me safe at my mother's breast. 11 Upon you I was thrust from the womb; since birth you are my God. 12 Do not stay far from me, for trouble is near, and there is no one to help. 13
4 Many bulls surround me; fierce bulls of Bashan encircle me. 14 They open their mouths against me, lions that rend and roar. 15 Like water my life drains away; all my bones grow soft. My heart has become like wax, it melts away within me. 16
5 As dry as a potsherd is my throat; my tongue sticks to my palate; you lay me in the dust of death. 17 Many dogs surround me; a pack of evildoers closes in on me. So wasted are my hands and feet 18 that I can count all my bones. They stare at me and gloat; 19 they divide my garments among them; for my clothing they cast lots. 20 But you, LORD, do not stay far off; my strength, come quickly to help me. 21 Deliver me from the sword, my forlorn life from the teeth of the dog. 22 Save me from the lion's mouth, my poor life from the horns of wild bulls. 23
6 Then I will proclaim your name to the assembly; in the community I will praise you: 24 "You who fear the LORD, give praise! All descendants of Jacob, give honor; show reverence, all descendants of Israel! 25
7 For God has not spurned or disdained the misery of this poor wretch, Did not turn away from me, but heard me when I cried out. 26 I will offer praise in the great assembly; my vows I will fulfill before those who fear him. 27
8 The poor will eat their fill; those who seek the LORD will offer praise. May your hearts enjoy life forever!" 28 All the ends of the earth will worship and turn to the LORD; All the families of nations will bow low before you. 29 For kingship belongs to the LORD, the ruler over the nations. 30
9 All who sleep in the earth will bow low before God; All who have gone down into the dust will kneel in homage. 31 And I will live for the LORD; my descendants will serve you. 32 The generation to come will be told of the Lord, that they may proclaim to a people yet unborn the deliverance you have brought.