The shares you own (usually) give you voting rights. Whether that makes any difference is another story.
But I'm not sure what people think the stock market is for? It exists primarily so that companies can access capital markets namely by issuing their own shares.
Historically for companies that were growing rapidly or had large capital needs, private markets weren't large enough to handle that. Times have changed, but the whole point of going public is to be able to raise capital by issuing shares.