The claim that Stalin fooled Trotsky comes from the latter's memoirs, written years after the event and with a clear axe to grind. In late 1923, Trotsky was recuperating from his various illnesses and was some distance from the capital. Stalin had cabled to Trotsky that it was not necessary for him to endanger his health by traveling such a distance:
The funeral will take place on Saturday, you will not make it in time. The politburo considers that in your state of health you should continue on to Sukhum. Stalin.
While this might be evidence of Stalin's perfidy, there was considerable chaos in Moscow at the time over Lenin's funeral. The decision to delay the funeral to Sunday was one that Stalin did not make. Additionally, there were multiple special trains coming in from the provinces for the funeral, some traveling a greater distance that Trotsky would have from Caucasus. Nor was Trotsky the only Soviet leader to miss the funeral; Rykov was in Italy and could not make it for health reasons.
What was soon clear was that Trotsky's absence damaged his political prestige. Trotsky could have made it to the funeral had he so desired; he had made a similar distance trip when Lenin was shot in 1918 and he was very familiar with the Soviet rail network from his service in the Civil War. But Trotsky during this period was acting as Lenin's heir apparent and this made him a number of enemies besides Stalin. While it is possible that Stalin opportunistically tried to dissuade Trotsky from attending, it is also plausible that Trotsky's own hubris got the better of him and he made a political blunder that he later rationalized as part of a wider conspiracy against him.
Source
Kotkin, Stephen. Stalin: Volume 1, Paradoxes of power, 1878-1928. New York: Penguin, 2014.