What specifically are you referring to?
Capitalism is the free exchange of goods. Slavery is in essence a forceful seizure. That's pretty easily separated. Communism, by far, has more in common with slavery than capitalism.
Capitalism is a government program, just like socialism and communism. It's "voluntary" in a very narrow sense within an involuntary structure.
In an absolute free society people don't exchange goods at all, they give each other things and exchange favors at a later time, which is much closer to a credit system. The vast majority of human history operated like this.
Exchange for money or bartering (which is a breakdown of exchange for money) are systems that were created by the advent of empires. Capitalism is purely a state program where a government under military force creates an artificial construct called a market. The first markets were created by military empires occupying previously stateless agrarian tribal societies under threat of force in order to facilitate an exchange of goods. This is the how capitalist markets developed. If you want to call that narrow definition "voluntary", then sure.