There is not one way in which media functions in society. Therefore, let me give you a few perspectives.
First, mass media is a main source of advertising. The media tries to sell things to people. Or to put it more precisely, companies use the media to sell their products. From this perspective, the media makes people into consumers.
Second, mass media shapes people's views of the world. To say that people are shaped my media is not an understatement. Things that are popular shapes the way people perceive the world and even themselves.
Third, from a more noble perspective, the media can be a useful way to obtain information, especially thoughtful programs that seek to be unbiased as possible.
I will add a link that deals with mass media and the use of tobacco.