You did the right thing. You have provided a safe place for the kitty to be until a vet visit.
Considering the condition of the kitty (fleas) you've contained the spread.
Make sure you wash throughly all the items in the cage.