I'd argue that it's *precisely* what it's there for. Every single law is there to define and guide your behavior. Most people think it's a good thing to guide you away from murder, theft, rape, arson, etc. It's widely thought to be necessary to live in together in a society; these laws are essentially universal in first-world societies.
The question isn't whether, but how much. Pigovian taxes (ones to encourage/discourage behavior rather than raise revenue) are a gentler method of limiting behavior than banning it outright. It's a good way to resolve tragedies-of-the-commons issues, another thing widely thought to be a reasonable province of government. When everybody doing exactly what's best for them leads to worse outcomes for everybody, we agree to abide by restrictions that leave everybody better off.
It's not always as obvious as regulating access to grazing land. It's an open question of whether we want to treat this as a commons to be managed, and if we do, whether a Pigovian tax is the best way to gently manage it while allowing market forces to continue to operate. But it's hard to take seriously the proposition that government has automatically no place in the question.