There's three stages of the movie business:
Production - Making the movie (pre-prod-post).
Distribution - Monetizing & placing movie in market.
Exhibition - Where audience buys & watches movie.
So in the movie industry of today, we make a movie... then a distribution company buys the rights to distribute the movie from you.
Usually this is for a limited amount of time (1-10 years).
At this point the distributor uses their personal and business connections to strike various deals across the country (and the world) with actual exhibitors.
Exhibitors include movie theaters, streaming services, television, etc...
Audiences hear about your movie from whatever channels they consume information.
After about seven exposures to the marketing of your movie, their minds finally go, "Hmm maybe I should check that out."
They take themselves to the exhibitor showcasing the movie based on the advertisement.
The audience member takes out their wallet, pays for the movie experience, and consumes the entertainment.
That ticket price then gets split in multiple ways: some goes to the exhibitor, some goes to the distributor, and finally, you get some of that money as the filmmaker.