Sure, some people just don't want to do the work themselves and hire a ghostwriter to do it for them, but there are a few reasons why a writer might want to consider ghostwriting, particularly if they're just starting out.
Earn Money by Practicing
You're getting paid to develop your skill whether you ghostwrite a novel, a short story, or an essay for another writer. You won't be credited for it, but that's beside the point. Every time you write, you have the potential to learn and grow while also earning money.
Write About Things You Wouldn't Normally Write About
Being a ghostwriter can be difficult since no writer wants someone else to take credit for their ideas. The easiest approach to avoid this problem is to never accept a ghostwriting assignment for which you know you'll develop a strong attachment or for which you'll have to give up your best ideas.
Acquire the necessary experience to strike out on your own
When I mentioned before that being a ghostwriter allows you to get paid to practice, I alluded to this. You should also use your ghostwriting skills as a springboard for your own career.