One of my kids likes to play
imagination games - she and her friends all pretend to be other people (often superheroes) and do exciting and interesting things.
These clearly have a lot in common with RPGing. But they don't have
rules - disagreements about what happens next are just resolved by people talking it over and reaching (or sometimes not reaching) agreement.
So why do RPGs have rules?
Some of the best answers to this question that I know come from Vincent Baker (
here,
here and
here)
<snip>
In summary: on this account, the function of RPG rules is to help
mediate and constrain the process of agreeing on the shared fiction; and not just by assigning authority ("It's your turn now to say what happens next") but by
shaping what is said so that it is surprising and even unwelcome to all participants.
There are approaches to RPGing, and examples of RPG rules, that at least to me don't seem to fit with Baker's picture. That doesn't necessarily make them "bad" RPGs. It does mean that they are meant to provide a different sort of experience from what Baker has in mind.
The two examples I'm thinking of:
(1) In classic dungeon-crawling and puzzle-solving D&D, some of the rules do have the function of easing negotiation - eg rules about likelihoods of finding secret door, and rules about surprise and encounter distance, and some elements of the avoidance and evasion rules. But some of the rules really seem like they're largely disconnected from "shared imagination" except that, at the end of the rule process, they spit out an answer to "what happens next" - I'm thinking about the combat rules in particular here, which involve playing a mini-wargame to answer the question "what happens when the PCs fight the monsters". And the idea of "unwelcome" outcomes doesn't really seem applicable.
(2) In "trad", post-DL D&D, the general expectation is that the players will work through the GM's scenario or story. There are non-D&D RPGs, like CoC, that are played similarly. Some of the rules in these RPG do seem to have the function of easing negotiation - eg Perception checks or Research checks will determine when and how the GM dispenses new information to the players - but the rules don't seem to have any function of generating "unwelcome" outcomes. In adventure modules intended for this sort of play, there are often instructions to the GM about how to blunt outcomes that might be unwelcome (eg if a Perception check is failed, here's another way to provide the new information; if a NPC is killed, here's a way to introduce a new NPC to play the same role as the dead PC would have played in events that are yet to occur in play but are intended to occur as part of the scenario). I would say that an important role of mechanics in this sort of play is to generate a degree of uncertainty
on the part of the players about the exact process that the GM is using to determine what happens next.
There are probably other reasons too why RPGs have rules, other things that those rules can do.