Hillary was going to be tough on Russia and impose stricter sanctions. For that reason alone, Trump was seen by Putin as the far more preferable option (and for the record, Bernie would have been too and perhaps Rubio/Christie/Cruz and a few others). Putin and Russia's actions to get Trump elected may have had more to do with not wanting Hillary than actually wanting Trump, but as the election got closer and Trump won the primary, that became moot and it was all about helping Trump/hurting Hillary. That
That Putin knewhad met Trump and perhaps had minor business deals in the past may have been a plus, and Michael Cohen certainly hashad ties to Russia though whether Putin was aware of the Michael Cohen connection (I'm sure he was because he does his homework), but whether Michael Cohen was seen as a factor in helping Trump is unclear. Precisely
Precisely how much under the table handshaking was goingwent on is difficult/impossible to say and we have to wait for the investigation to play out, but it's highly likely that Putin was in the anybody is better than Hillary camp and him knowingwhether he was also in a Trump gave him an inroadis my secret buddy camp too is unclear.
On Trump's softness on Russia
Trump also refused to apply the sanctions that congress passed against Russia, so it seems that he did do a favor for them. You can speculate as to whether that was in return for their help getting him elected.
There's an answer above that Trump struck Assad for chemical weapons use. Yes, but after giving the Russians a call telling them he would do that.
When interviewed, and the interviewer told Trump that Putin was a killer, Trump's answer was "there are many killers". Trump doesn't seem at all interested in putting Putin down. He has one military strike against Syria for chemical weapons use, but beyond that, he's talked well of Putin and done him a favor by not implyingapplying the sanctions that congress wrote into law with a veto-proof majority.
Whether this is evidence that Trump is returning a favor is hardimpossible to say, but Trump has been accused of being soft on Russia by many. Article on that, and another.