The statement is from the very end of Hilchos Shemittah Ve'Yovel. It follows a halachah where Rambam notes that the tribe of Levi did not receive a share of the Land of Israel to develop, nor serve in the army, but instead their role was to serve God and teach Torah to Israel. Rambam follows this by stating as follows:
Not only the Tribe of Levi, but each and every individual human being, whose spirit moves him and whose knowledge gives him understanding to set himself apart in order to stand before the Lord, to serve Him, to worship Him, and to know Him, who walks upright as God created him to do, and releases himself from the yoke of the many foolish considerations which trouble people - such an individual is as consecrated as the Holy of Holies, and his portion and inheritance shall be in the Lord forever and ever. The Lord will grant him adequate sustenance in this world, just as He granted to the priests and to the Levites. Thus did David, peace upon him, say, "O Lord, the portion of my inheritance and of my cup, You maintain my lot."This is cited by many people to prove that, according to Rambam, anyone who wants to devote themselves to studying Torah, and reach the pinnacle of Jewish existence, does not need to serve in the army, and should be financially supported by the rest of the Jewish People, just as the tribe of Levi was supported by the rest of Israel.
However, Rambam does not, and could not, mean anything of the sort.
First of all, Rambam is very clear about his views on taking money for engaging in Torah:
One who makes up his mind to involve himself with Torah and not to work, and to support himself from charity, has profaned God’s Name and brought the Torah into contempt, extinguished the light of religion, brought evil upon himself, and has taken away his life from the World-to-Come... (Hilchos Talmud Torah 3:10)Rambam was somewhat of an aberration from normative tradition in his views on these matters, but not as much as one might think. He does, reluctantly, permit teaching the Written Torah for money, where such is the norm, and although he opposes receiving money for teaching Oral Torah, he does not do so with the same vehemence that he opposes taking money for studying Torah (Hilchos Talmud Torah 1:8-10). Other Rishonim and Acharonim often permitted taking money for teaching Torah, though almost never for studying Torah. In any case, it is clear that Rambam viewed a lifestyle of being supported in studying Torah via charitable donations - the modern kollel system - as being utterly, utterly wrong. (This is even though the state of Torah study in his part of the world was generally rather poor, especially compared to today.)
What, then, is Rambam talking about at the end of Hilchos Shemittah Ve'Yovel?
First of all, he is not making a halachic statement here at all. As is common with the closing paragraphs of the different sections of the Mishneh Torah, Rambam here is presenting mussar rather than halachah. He is not contradicting, or even qualifying, the halachos regarding taking money for Torah that he discussed in Hilchos Talmud Torah chapter 1, nor the halachos regarding going to the army that he discusses in Hilchos Melachim u'Milchamos chapter 7. Instead, he is praising an ideal - which certainly does not include taking money for Torah, as he has already made clear.
But what is the comparison with the tribe of Levi? First of all, it is not a complete comparison. It does not, for example, include an exemption from military duty in either milchemes reshus or milchemes mitzvah (since it is not mentioned in Hilchos Melachim u'Milchamos). Rather, it is a comparison vis-a-vis devoting one's life to God. It is a comparison vis-a-vis mussar goals and ideals, not halachic exemptions.
Second, insofar as Rambam does equate Torah scholars with the tribe of Levi with regard to material sustenance, he makes the meaning of this clear elsewhere:
Anyone who makes economic use of the honor of the Torah takes his life from this world... However, the Torah permits scholars to give their money to others to invest in profitable businesses (on their behalf)... and to receive priority in buying and selling merchandise in the marketplace. These are benefits that God granted them, just as He granted the offering to the Kohanim and the tithes to the Levite... for merchants occasionally do such things for each other as a courtesy, even if there is no Torah scholarship to warrant it. A Torah scholar should certainly be treated at least as well as a respectable ignoramus. (Commentary to the Mishnah, Avos 4:7)In Rambam's view, Torah scholars, like Kohanim and Leviim, receive benefits, but the benefits are of a different nature. They involve the investment of funds, and assistance in business, rather than financial grants. (This is similar to the Yissacher-Zevulun relationship, which, according to Chazal, was nothing at all like it is popularized today; rather, it involved Zevulun marketing the produce that Yissacher farmed.)
What about Rambam himself? There is a widespread belief that he was entirely dedicated to his studies, supported by his brother, until his brother died at sea and Rambam was forced to provide for both his own and his brothers’ families, whereupon he began to work as a doctor. But this is not the case. Rambam learned medicine while his family was still living in Morocco. Upon moving to Egypt, Rambam soon rose to prominence as a physician. He also traded in gemstones, and his brother assisted with his investments, enabling him to devote much time to his studies. At no point was he simply receiving money from his brother. His brother was simply investing Rambam's own merchandise and earnings, just as Rambam permits Torah scholars to have done on their behalf.
(Incidentally, Rambam in Hilchos Shemittah Ve'Yovel is not even only talking about Jews; he speaks about "anyone in the world." He is actually referring to anyone, Jew or non-Jew, seeking an ascetic lifestyle of the pursuit of knowledge. See further discussion here.)
In conclusion: In Hilchos Shemittah VeYovel, Rambam is not remotely describing someone studying in kollel, being exempt from military duty and supported by charitable contributions. His view on this remains as he expresses it elsewhere: that such a person "has profaned God’s Name and brought the Torah into contempt."
UPDATE: See too this post: What Does The Torah Tribe Do?
Further sources/ resources:
- The Economics of Torah Scholarship in Medieval Jewish Thought and Practice
- Yehudah Levi, Torah Study
- אליעזר דניאל יסלזון, "פרנסתם של לומדי תורה - שיטת הרמב"ם", תחומין כרך לב