The Gemara records that Avraham was called yedid – “God’s beloved” – and then continues by offering a midrashicinterpretation of the passages in Sefer Yirmiyahu (11:15-16) where we find a conversation between God and the yedid.
Rabbi Yitzhak said, At the time of the destruction of the Temple the Holy One, blessed be He, found Avraham standing in the Temple. Said He, ‘What is My beloved doing in My house?’ Avraham replied, ‘I have come concerning the fate of my children.’
Said He, ‘Thy children sinned and have gone into exile.’
‘Perhaps,’ said Avraham, ‘they only sinned in error?’
He answered, ‘She hath wrought lewdness.’
‘Perhaps only a few sinned?’
‘With many,’ came the reply.
‘Still,’ he pleaded, ‘You should have remembered unto them the covenant of circumcision.’
And He replied, ‘The hallowed flesh is passed from thee.’
‘Perhaps had You waited for them they would have repented,’ he pleaded.
And He replied, ‘When thou doest evil, then thou rejoicest!’
Thereupon he put his hands on his head and wept bitterly, and cried, ‘Perhaps, Heaven forfend, there is no hope for them!’
Then came forth a Heavenly Voice and said, The Lord called thy name a leafy olive-tree, fair with goodly fruit: as the olive-tree produces its best only at the very end, so Israel will flourish at the end of time.
In his Ben Yehoyada, the Ben Ish Hai interprets Avraham’s placing his head in his hands as follows. Avraham understood that both the activities of the Jewish People -represented by the hands – as well as their thoughts and ideas – represented by the head – were equally involved in evil. He therefore placed his head in his hands and cried out in prayer so that he could appeal for forgiveness on behalf of those two elements together.