Yes, I think that Erdogan is right about the European Union excluding Turkey from joining because of its Muslim population because the population of most countries in the European Union are very similar, while Turkey's is a stark contrast. I believe another reason why the European Union refuses to accept Turkey is because their government can be at times repressive.
Erdogan claims that the European Union excludes Turkey from membership due to its large Muslim population. However, Erdogan is incorrect in his beliefs. The European Union has very strict membership guidelines; and the process for joining the Eruo-Zone is a long one. In short, there are several factors that prevent Turkey from joining the European Union, but its large Muslim population is not one of them.
There is probably a kernel of truth to Erdogan's assertion, but there are many other reasons for Turkey's exclusion, many of them having to do with Erdogan himself. Turkey has had a lot of issues, human rights violations, etc. that make the EU hesitant to include the nation. Erdogan has said and done several things just in the last few months that have brought him and the country to international prominence for the wrong reasons.
Turkey is not a Christian country but a Muslim one, unlike all the current or prospective EU states, which have been shaped by a shared legacy of Christian values, history and culture. Indeed Turkey’s history represents a clear rejection of any Christian tradition, from the centuries-long Ottoman Muslim conquest of Byzantine Christian territories, to the early twentieth century population exchange with Greece which removed millions of long-established Christian families from Turkish territory. Most recently, Turks have elected to government a party with islamist roots, likely to undermine the country’s secular constitution.