This issue is well explained in FOTR (The Fate of the Romanovs) by King and Wilson, in the chapter "A traitor to revokution".
I'll try to summarize for you (hope my english will be understandable to you).
Lenin and his collegue Sverdlov wanted Nicholas to have a trial in Moscow, so sent Jakovlev to fetch him and his family in Tobolsk. They wanted Jakovlev to take them to Moscow for the trial. But the Ural Soviet want to be personally responsible for the Romanovs; the Ural region was the most revolutionary of whole Russia; population was mostly of workers, who wanted to see Nicholas dead, considering him a tyrant. The Ural Soviet feared that in Moscow Lenin would process Nicholas and them let him go abroad in exile; at the contrary, they wanted him dead.
While Jakovlev was going to Tobolsk, and while he was preparing the IF to move, The Ural Soviet exchanged telegrams with Sverdlov, trying to persuade him to let them having the IF in Ekaterinburg. Jakovlev knew nothing about this, and didn't like Avdeev (a member of the ekaterinburg soviet) travelling with him to Tobolsk. He didn't like Ural soviet, he thought (and was right) that they were not able to keep the IF safe. He was sure they wanted them dead.
Jakovlev was meant to go to Moscow, and when he realized that the Ural Soviet won't let him pass through Ekaterinburg (the railway Tjumen' - Moscow he used to transfer Nicholas, Alix and Maria passed through Ekaterinburg - it was a part of Transiberian), he tried to pass through another railway, the Omsk - Moscow, a longer but safer way. In the meantime the Ural Soviet was still trying to persuade Sverdlov. In the end, the Ural Soviet got it; Sverdlov cabled Jakovlev to go back to Ekaterinburg. Jakovlev did not want at first (for the reasons explained) but he had to obey to Sverdlov. In Ekaterinburg he arguem violently with the heads of the soviet (goloshchokin and Beloborodov) but no way. He was eventually arrested when got off the train; the ural soviet declared he was "a traitor to the Revolution" because he tried to "safe" the Romanovs and sent him in prison. Truth was, he was only following the orders Sverdlov had gave him.
He was later "saved" by Sverdlov himself, but it seems he really became a traitor in late 1918, joing the White cause.