It works differently for different teams. In some cases, two people work together on the same piece of fiction. If you want to know how that works, you should check out Uncle Jim's thread in Novel Writing. I know at some point, he's posted how he and his wife write together to produce a book.
Another person to ask if you're interested in serious collaboration is CathyC, as she has a writing partner for all her novels as well.
As far as being the sole writer of a novel, but working with another person when stuck, I've done that a couple of times with my first novel. When I came to a place where I knew approximately what needed to go next, but I couldn't find the words, I gave the mess to my SO, and had him write the next sentence or two. Yes, I ended up with a food fight between my characters, but it got me unstuck and I finished the novel.
If you simply want to work with a group of people to hold yourself accountable, you can work with a writing group online or off. Here at the cooler, we've got numerous threads devoted to reporting in on a regular basis, and I find it helpful to be part of one of these (The Weekend Progress Report, over in the Humor forum). Of course, come Friday, I'm thinking, "Ouch! I've written nothing! What am I going to say?" At that point, I come up with a really creative excuse, or more likely, words on computer screen to report. Former and current members of WPR have gone from unpublished to published, so we must be doing something right!
Then there's the off-the-cuff unstructured sort of collaboration that folks are doing here and there in the Cooler. There are two people writing a novel, alternating chapter by chapter (check sigs to find out who they are
), there are numerous threads in WEPG where consecutive posters work through a story, three or five words or a paragraph at a time. Play around, make friends, and find some other people who want to do the same thing, if that's your dream. (Zero, I think these last methods are more like a music jam than the others, though the results aren't always as cohesive.)