Shaykh al-Islaam Ibn Taymiyyah (rahimahullaah) said in Majmu' al-Fatawa (1/126):
Translation:
And if you affirm intermediaries between Allaah and His creation - like the veil which is between the king and his subjects - in that they (the intermediaries) raise to Allaah the needs of His creation, such that Allaah guides His servants, grants them sustenance through their intermediation, hence, the creation ask them and they in turn ask Allaah, just as the intermediaries (function) with the kings, they ask the kings for the needs of the people due to their closeness to them (the kings) and the people ask them (the intermediaries), out of respect for them so that they ask the king directly, or because their requesting from the intermediaries is more beneficial for them than asking from the king (directly) due to them being closer to the king than the one making the request for needs, so whoever affirmed intermediaries upon this angle, then he is a kaafir, mushrik, his repentance should be sought, so either he repents or he is killed (as an apostate).
Note
There are numerous concepts at work when a person solicits du'a from the dead, and there are also underlying assumptions and beliefs associated with making these requests from the dead for them to supplicate to Allaah on behalf of the one asking them - and all of this falls within what Allaah described as shirk and kufr in the Qur'an which is making du'a to other than Allaah (asking the dead to make du'a is du'a in itself and is asking for their intercession), treating them as intermediaries, assuming that Allaah's relationship to the creation is like that of the kings with their subjects through the intermediation of ministers and their likes, soliciting their intercession (which actually means to ask another to make supplication - see this article). This matter will be elaborated upon in other articles.