Some publishers demand that their writers sign over their full copyright as part of a publishing deal: this is rarely a good thing for the writer, and but can be very lucrative for the publisher.
All sorts of different rights coexist in a single piece of work, and each can be sold: for example, rights to publication in hardback and paperback book form in home and foreign territories, rights to newspaper and/or magazine serialisations, e-book rights, character licensing rights, radio serialisation rights, and TV and film rights. If that seems like a lot to you, bear in mind that it is not an exhaustive list and each different set of rights could generate income for whoever owns them.
You might assume, therefore, that the best contract from the writer’s point of view gives up as few rights as possible to the work, because then all of those other rights might well be sold elsewhere: but that isn't necessarily the case. The best owner for rights is the one who is going to sell them, whether that's the agent, the publisher or the writer, as that will then generate further income for the writer—and with writers’ incomes usually being so low, that could be a very good thing.