Being a volunteer moderator shouldn't hurt your chances of getting a job in community management (as long as you did a good job as volunteer moderator, of course). If anything, it should strengthen your chances, at least if you can explain ways in which your experiences as a volunteer moderator helped you gain the skills you need to be a good moderator.
I have served as a volunteer moderator of various online communities on Reddit, Discord, and other platforms over most of the past decade. Eventually, I realized that community management was something I was really passionate about, and decided to actively look for paid positions in that field. And my time as a volunteer moderator definitely helped me do that: Before I started my current job as a Community Manager at Stack Exchange, Inc., I was previously a volunteer moderator for the Role-Playing Games Stack Exchange. Likewise, I was previously a CM for Nova Drift, and a YouTube Moderator for Rooster Teeth; I was a volunteer moderator in (parts of) both communities before that as well. My work as a volunteer mod, and especially the relationships I established during that time, definitely helped me get those paid positions.
Take my work as CM for Nova Drift, for example. Nova Drift is published by Pixeljam Games, a small independent studio. I was originally just a regular user in Pixeljam's main Discord server. However, I was active in the community and in greeting new users as they joined; the staff noticed my helpfulness, and invited me to be a moderator. Later, when Nova Drift was in a pre-release state, they started a separate Discord server for that game; soon afterwards, they invited me to be a moderator there as well. Eventually, the developer reached out to me to see if I would be interested in a paid position as Localization Manager (to coordinate the crowdsourced translation effort); a month later, the developer expanded my role to Community Manager as well (after confirming that I was interested).
Similarly, I've been a volunteer moderator of the Rooster Teeth subreddit for nearly a decade. (Though it's an "unofficial" community not run by the company, it has been a major hub of community interaction with each other and the RT staff.) In addition, I became a moderator for Rooster Teeth's RTTV live chat during the RTX at Home 2020 virtual convention (following an application process in which I referenced my experience as a mod of the subreddit); I was invited back as a permanent moderator shortly afterwards. In addition, at the start of this year, RT's Director of Community reached out to a number of existing volunteer moderators to offer them paid positions as moderators of various parts of their community, and I became one of their YouTube Moderators (to moderate the comments on RT's YouTube videos and community posts).
Finally, in mid-2021, I was hired as an Associate Community Manager for the Curator Support Team at Stack Exchange, Inc. This process was more of a typical interview process, as opposed to the more informal hiring process for my previous roles. I applied to an open Community Manager position listed on our careers page. I think I included some of my volunteer moderation on my resume; I definitely also used my cover letter to showcase my extensive volunteer mod experience (both on RPG.SE and elsewhere), as well as my paid work relating to community management (for Nova Drift and Rooster Teeth). Especially because the position involved working with moderators and high-rep users in the network's communities, I was able to explain (in my job application and interviews) how my time as a moderator on RPG.SE made me an excellent choice for the job.
If you're good as a volunteer moderator, you can use that to strengthen your application. Hopefully, the company will see the value you bring as someone who is already in touch with the community's wants and needs, and especially understands the perspective of the volunteer moderators you'd be working with as a CM.
If the company just wants to exploit you, and chooses to retain you as a volunteer mod rather than an employee specifically so they don't have to pay you, it's not a company you'd want to work for anyway. (Of course, there are plenty of other reasons they might not hire you, too; maybe they don't have the budget to hire more CMs, or someone else was a better candidate for the position.)