Whether or not you volunteer your time tells companies quite a lot about you. Choosing not to tells them "I'm self-centered and I don't care about my community or causes larger than myself."
Like it or not, these companies don't exist to provide you a job. They are free to shape their workforces any way they like, and showing preference to those who volunteer their time is their way of saying "we prefer people who are not just here for a paycheck."