Why Buddha didn't want him to be called 'friend' by the monks? Referring these lines from 'The Discourse to Prince Bodhi':


  As I approached, Prince, the group-of-five monks were unable to
  continue with their own agreement, and after coming out to meet me,
  some took my bowl and robe, some prepared the seat, some placed the
  water for washing the feet.
  
  Then they addressed me by name and with the word ‘friend’.
  
  When this was said, Prince, I said this to the group-of-five monks:
  “Do not address the Gracious One, monks, by name and by the word
  ‘friend’, the Realised One, monks, is a Worthy One, a Perfect
  Sambuddha. Lend an ear, monks,........" 


Is it wise to get respect by compulsion?

Is it wise to claim "I am The Greatest/Perfect One" even if you're The Greatest/Perfect One ?

If that's OK, then why did he call his  teachers Ālāra Kālāma and Uddaka Rāmaputta as 'friend' even before he started learning from them? How can this be justified?
When they first saw him they thought, &quot;He is inferior to us (because he is given to luxury, forsaking the striving, etc.).&quot;
When he approached them they no longer thought that, but still they called him &quot;friend&quot;: which I understand to mean &quot;my comrade, my equal&quot;.
The Buddha corrected them because he wanted them to learn the Dhamma from him, and it was important that they respect him as a teacher (because if they didn't respect him and didn't accept him as a teacher and listen to his teaching then that would be to their harm).
They were telling him that, as far as they knew, he had no attainment and no knowledge worth teaching:

For a third time, Prince, the group-of-five monks said this to me: “But you, friend Gotama, by that ascetic lifestyle, that practice, that difficult way of living, did not attain states beyond ordinary human beings, a distinction of what is truly noble knowledge and insight.
So how can you now, given to luxury, forsaking the striving, gone back to luxury, attain states beyond ordinary human beings, a distinction of what is truly noble knowledge and insight?”

He contradicted them:

When this was said, Prince, I said this to the group-of-five monks: “Are you aware, monks, of my having spoken to you like this before?”
“Certainly not, reverend Sir.”
“The Realised One, monks, is a Worthy One, a Perfect Sambuddha. Lend an ear, monks, I will instruct you about the attainment of the Deathless, I will teach the Dhamma, and following the path as it has been preached, after no long time in regard to that good for which young men of good family rightly go forth from the home to the homeless life, that unsurpassed conclusion to the spiritual life, you will dwell having known, experienced, and attained it yourselves in this very life,” and I was able, Prince, to persuade the group-of-five monks.


This version of the story includes the following explanation:

ON seeing their old teacher approach, the five bhikkus agreed among themselves not to salute him, nor to address him as a master, but by his name only. &quot;For,&quot; so they said, &quot;he has broken his vow and has abandoned holiness. He is no bhikkhu, but Gotama, and Gotama has become a man who lives in abundance and indulges in the pleasures of worldliness.&quot; But when the Blessed One approached in a dignified manner, they involuntarily rose from their seats and greeted him in spite of their resolution. Still they called him by his name and addressed him as &quot;friend Gotama.&quot;
When they had thus received the Blessed One, he said: &quot;Do not call the Tathagata by his name nor address him as 'friend,' for he is the Buddha, the Holy One. The Buddha looks with a kind heart equally on all living beings, and they therefore call him 'Father.' To disrespect a father is wrong; to despise him, is wicked. The Tathagata, the Buddha continued, does not seek salvation in austerities, but neither does he for that reason indulge in worldly pleasures, nor live in abundance. The Tathagata has found the middle path.

This is from an 1894 version titled The Gospel of Buddha by Paul Carus -- I don't know which original text this is a translation of (or whether it's even translation instead of invention).
One place where the story appears is the Ariyapariyesana Sutta (MN 26) which matches the story in the OP. This one is addressed to monks rather than to &quot;Prince Bodhi&quot; so I suppose there are several versions of this story.