He said something to that effect at one point, that Rolling Rock was just whatever beer he had around, so he decided to make it a thing. He eventually got a Rolling Rock clock that he's shown a few times, too.James did the advertising for free since his videos (which were watched mostly by preteens/teens back in the day) undoubtedly produced many sales for Rolling Rock over the years. I have no idea how much contact James or anyone else ever had with Rolling Rock, Yeungling, or any other brewery/their parent corporations, but it seems likely they rebuffed him with their policy about ads and sponsorship and he decided to do it for free. Maybe it was a cheap beer he liked and decided to make a part of the character, I don't know.
I figure he's probably beloved at Rolling Rock HQ, and probably gets all sorts of free merch and factory tours and drinks for free in place of any kind of legally-binding advertising contract. I always figured if I were he, I'd just design and print up increasingly goofy beer labels every episode, and just put those over whatever bottles I'm using.