While you can legally show actors drinking beer in a commercial, you'll almost never see any alcohol brand do it. This regulation comes from TV network standards.
Almost all networks look down on alcohol consumption on camera, so brands refrain from putting any alcohol-drinking visuals in their commercials so it doesn’t get banned.
ABC, for example, states that "visual representations or sound effects of drinking" are "generally not acceptable" in advertisements shown on the network.
If a beer company produced a commercial with someone consuming alcohol, it wouldn't be shown on a massive network like ABC, losing viewership and revenue.