You'd be issued stock options giving you the ability to buy the company's stock at a very low price. These typically vest over time so that you can't just take the equity and quit. The paperwork is a bunch of legal forms. Have a startup lawyer look things over to keep yourself covered.
It depends on what country you live in... you'll have to research the incorporation laws of the country you specifically live in.
In the UK, you can just decide how many shares the company has, and sell them for whatever amount per share you decide - that way you split the company between several founders. Of course, if you want more complicated stuff, like vesting, you'll probably want to speak to a solicitor.