"Sahi Bukhar" Hazrat Ibne Abbas said, that Rasoolullah (S.A.W.) passes by two graves and said "here are suffering anguish because one of them is backbiter and other did not take precaution for wine". Ibne Abbas said, "Rasoolullah (S.A.W.) takes a grew branch and make into two pieces and key on each one grave and said that "until these branch get dried they will feel relief from anguish".
But we does not follow this Hadees in same manner, flowers just for respect.
أَلَا إِنَّ أَوْلِيَاءَ اللَّهِ لَا خَوْفٌ عَلَيْهِمْ وَلَا هُمْ يَحْزَنُونَ - 10:62