The formal change of command was necessary in order to get full cooperation from the crew. Otherwise, if Jellico was seen as a substitute captain, there was a greater risk of him not being taken as seriously ("oh well, we don't have to be as loyal, because once the mission is done he's gone and we'll have Picard back"). In addition, with the high risks of Picard's mission, there was a fairly good chance of him not making it back... in which case Jellico would be captain anyway.
Why wasn't Riker given command? Well, honestly I don't see any reason why he couldn't have been, with Jellico as the "negotiations officer". But perhaps the nature of the potential conflict wasn't within HQ's confidence that Riker would be the best man for the job. And as others suggested, a little pay back for his continued declining of other commands.