Until recently, you could only purchase games via physical retail, from department stores or video game retailers, but then came the advent of the internet, where you could purchase games, or download free games.
Not all of the games you see and hear about are free. You can purchase them via digital distribution, direct from the developers, through online retailers, such as steam, humble bundles, EA Origin, and GoG. As of late, you can now also purchase games through Kickstarter, Indiegogo, and other crowd-sourcing websites, even Patreon allows you to purchase games directly from developers in exchange for continuous support.
There are also many avenues where you can download free games. There are some methods that allow you to completely bypass the restrictions of purchase and acquire paid games for free, but those avenues are illegal and frowned upon as they hurt the economy, the developers, the market and ultimately may hurt you. However, there is a silver lining, as there are also legal ways to download those free games.
The very same avenues mentioned above, do, on occasion provide free games, either to promote upcoming sequels, or upcoming games from the same developers, there are also games added to the stores, completely free of charge.
Other methods are through blogging sites, forums and websites with free online games. Blogging is the best free marketing avenue for both professional and indie developers. Who better to market their games, than themselves? There are developers, who will make blogs, such as on those on tumblr, centered around the game they are currently developing. They post and talk about their game, in order to generate a following of people, excited to see their game. After garnering fans and supporters, a developer may decide on whether to give the game out for free, or sell it.
There are developers in forums, such as the gaming-centered threads on Reddit, where they distribute their games for free. They have no motive to make profit from their labour or gain popularity. half of the time, they do it for critique, on where they can improve their games, in order to make the next one better. Then there are some developers, who do it solely for the sake of entertainment and gaming.
On tumblr, all you have to do is search for gaming related blogs and a majority of the returned links will be indie Dev blogs taking about their new games. If you're a frequenter of reddit, subreddits pertaining to Game development engines and Gaming will have threads where people post games for free, in the hopes of garnering fans ad critique for them to improve their games.
I personally get my free games from the Reddit forums. There are many more avenues to get free games. Start searching, and I hope you have a fun time experiencing creative content others have made for our entertainment.