Praise be to Allah.
It is not permissible for an employee to take what is given to him because of his job, because that is a kind of bribe, which is haraam, even if that is not his intention. The one who gives this money usually gives it only so that things will be made easier for him or so that he will be singled out for good treatment in the future.
But if something is given to an employee because of blood ties or friendship, and not because of his job, then there is nothing wrong with that, and he should accept it, following the example of the Prophet (peace and blessings of Allaah be upon him), who used to accept gifts and respond in kind, as was narrated by al-Bukhaari, 2585. What is meant by “respond in kind” is that he used to give the giver gifts in return for his gift.
The difference between gifts that are forbidden and gifts that are permissible is that gifts that are given because of a person’s job or position are haraam. So he should think about it: if he was not in this job, would he be given this gift or not?
This is what the Prophet (peace and blessings of Allaah be upon him) stated when he said: “Why doesn’t he sit in the house of his father and mother and see whether he is given a gift or not?” Al-Bukhaari (7174) and Muslim (1832) narrated that Abu Humayd al-Saa’idi (may Allaah be pleased with him) said: The Prophet (peace and blessings of Allaah be upon him) appointed a man from Banu Asad in charge of the zakaah and when he came he said, “This is for you and this was given to me.” The Messenger of Allaah (peace and blessings of Allaah be upon him) stood on the minbar and praised Allaah, then he said: “What is the matter with a worker whom we send out, then he comes and says, ‘This is for you and this is for me?’ Why doesn’t he sit in the house of his father and mother and see whether he is given a gift or not? By the One in Whose hand is my soul, he does not take anything but he will bring it on the Day of Resurrection, carrying it on his shoulders, even if it is a camel groaning, a cow mooing or a sheep bleating.” Then he raised his hands until we could see the whiteness of his armpits and said: “Have I not conveyed (the message)?” three times.
This hadeeth indicates that gifts that are given to workers because of their work are haraam, and that the worker will come on the Day of Resurrection carrying whatever he took of such gifts, even if it was a camel or a cow or a sheep – Allaah forbid.
It says in Fataawa al-Lajnah al-Daa’imah (23/548):
What is the Islamic ruling on one who is given money when he is at work, without asking for it, or he tries to take money by means of tricks. For example, the mayor or Shaykh of a village to whom the people come so that he will give them certificates, because they are inhabitants of his village, and they give him money for that – is it permissible for him to take that? Is that money regarded as halaal? Can we take as evidence for it being halaal the hadeeth of Saalim ibn ‘Abd-Allaah ibn ‘Umar, from his father ‘Abd-Allaah ibn ‘Umar, that ‘Umar (may Allaah be pleased with him), said: The Messenger of Allaah (peace and blessings of Allaah be upon him) used to give us gifts and I would say: “Give it to one who is more in need of it than me.” He said: “Take it. If any of this wealth comes to you without your hoping for it or asking for it, then take it and keep it, and if you wish then give it in charity, and if nothing comes to you, then do not hope for it.” Saalim said: ‘Abd-Allaah did not ask anyone for anything, and he did not refuse anything that was given to him. Agreed upon.
Answer: If the situation is as described, then giving money to this mayor is haraam, because it is a bribe. The hadeeth of Ibn ‘Umar (may Allaah be pleased with him) has nothing to do with this matter, because it has to do with one who is given something from the bayt al-maal of the Muslims by the one who is in charge of the Muslims, without him asking for it or hoping for it. End quote.
To conclude, your friend has to refuse to take this money no matter how hard the people insist on giving it. He should inform them that this is not permissible for him. This will soothe their feelings and will spread awareness of this shar’i matter of which many people are unaware.
And Allaah knows best.