Lord Rama preferred Sugriva instead of Vali to find Sitadevi because Lord Rama had come to Kishkindha to help Sugriva. After Ravana kidnapped Chhaya Sita, Lord Rama and Lakshmana, for deluding ignorant people, acted as if they lamented the abduction of Sitadevi. But actually, Sitadevi was in Kailasa, being worshipped by Lord Shiva and Umadevi. This incident is clearly stated in the Kurma Purana.
Now, Lord Rama and Lakshmana went further and met Shabari, whose hermitage was near the Pampa River, in Hampi, Karnataka. She fed Rama and Lakshmana sweet berries with pure devotion. After accepting Shabari’s berries, she told Rama and Lakshmana to go to Rushyamooka Parvata, where He can find Sugriva and Hanuman. As Shabari directed, Rama and Lakshmana went toward Rushyamooka Parvata. Along the way, they met a Kabandha named Raakshasa. Rama and Lakshmana cut the hands of Kabandha with their swords. This Kabandha was actually a Gandharva by the name Dhanu, who was cursed to be a demon. Now, this Dhanu Gandharva was freed, and he went to the Devaloka.
From here, Lord Rama and Lakshmana were coming to Rushyamooka Parvata, and Hanuman met them, took them to Rushyamooka Parvata, and made Sugriva befriend Rama. Now, the lesson we get here is that if you stay on Hanuman’s side, then only Lord Rama will accept you. Because Hanuman is the greatest devotee of Lord Rama. So, Lord Rama will only bless you if you are on Hanuman's side. Sugriva was on the side of Hanuman; that’s why Rama accepted Sugriva as his friend. Vali also, though was a great devotee of Lord Rama, but since he wasn’t on the side of Hanuman, Lord Rama didn’t accept him.
Another reason is that Lord Rama didn’t come to Rushyamooka Parvata because He thought, ‘O Sugriva is just like me, who lost his wife.’ The real reason behind it is different. Lord Vishnu decided to incarnate as Rama. Lord Brahma instructs all the devatas to incarnate as vaanaras to serve Lord Rama. So, all these vaanaras had incarnated to serve Lord Rama. If Rama had taken Vali’s help, then Vali, who had already defeated Ravana, could have killed Ravana immediately and could have brought Sitadevi back. But that would lead to a serious problem. Because it was Rama’s sankalpa to kill Ravana. So, Rama is the one only one who would kill Ravana. Another thing is, the Sitadevi whom Ravana had abducted was Chhaya Sita and not the real Sitadevi.
Third thing, if Rama chose Vali for help, then the sole purpose behind the incarnations of all these 60 crore vaanaras (to serve Lord Rama) would have gone to waste. They could have missed the great opportunity to serve Lord Rama. Lord Rama doesn’t need anyone’s help. He could have killed Ravana if He wished, from Ayodhya itself. But apart from killing Ravana, He had to give darshan to the sages, who had done penance for thousands of years to meet Rama. Plus, He had to free people from curses and kill the evil people. Plus, if He had taken the side of Vali, then the exchange of Chhaya Sita with real Sita through Agni Pariksha wouldn’t have happened.
So, for all these reasons, Lord Rama didn’t choose Vali and chose Sugriva. Another reason is that Vali had performed Adharma by keeping Sugriva’s wife, Rumadevi, with him. That’s why Rama also didn’t prefer Vali, because he himself had claimed Ruma, who was Sugriva’s wife. So, one should never consider Rama as equally distressed as Sugriva was, because both lost their wives, Ramaa and Rumaa. No. Ramaa’s or Sitadevi’s Akruti or Chhaya Sita was in Ashokavana of Ravana, so Rama knows it. He just acted as if He was crying, hugging trees, and seeing Sitadevi everywhere. Lord Rama’s sole purpose in coming to Kishkindha was to bless Hanuman and to help Sugriva. In return, Sugriva promised Rama to help Him in finding Sitadevi.
All this was done so that the vaanaras led by Sugriva, Hanuman, and Angada could also get the fortune to serve Lord Rama in His avatarakarya. They earned punya by contributing their best to the Raamakaarya. This Vaali, in the Krishnavatara, came as Arjuna and got the opportunity to serve the same Rama who was now Krishna in Dwapara Yuga.
Hope this helps!
Jay SriRam!
ShriKrishnarpanamastu!