I actually don't know the details of Redbox. The specific example I remember is Blockbuster video, which used to get copies of movies for virtually free, in exchange for sharing a portion of their profits with the studios: https://www.quora.com/How-much-do-movie-rental-stores-e-g-Bl...
I think the studios agreed to this because of market segmentation, for any given movie there are people who have no interest in paying $20 to own it, but will pay a few bucks to rent it once or twice. If the studios didn't support this model they'd be leaving money on the table.
It's all ancient history at this point so my memory is fuzzy, but I think hobbyist stores actually had the better business model by that measure (they'd focus on a limited selection of classics that people would rent again and again). Then Blockbuster came along with these studio deals they were able to negotiate based on their volume, allowing them to offer practically unlimited copies of new releases. In conjunction with a decent selection of classics this enabled them to lure customers away from the hobbyists. A combination of pressure from the studios and the emergence of competitors with lower operating cost (Redbox, Netflix etc.) later crushed Blockbuster. And watching the studios raise their fees until Blockbuster collapsed surely contributed to Netflix's decision to produce a lot of original content. And now we're caught up to the present day.
This article (admittedly from 2008) says studios hate Redbox. And that Redbox gets its DVDs from regular movie wholesalers (I assume where Walmart gets them too).
https://arstechnica.com/tech-policy/2008/10/universal-studio...