"Yesterday, I ran 5 kilometers."
Yes. 'キロ' means 'kilometers/キロメートル' in this case.
If I say 'きのう、肉を５キロ食べました', it means 'Yesterday, I ate a meat 5 kilograms. ' This キロ is キログラム.
Because almost they are able to distinguished each the word 'キロ'.
And we use 'キロメートル' and 'キログラム' as well.
I don't know the history of these words. Perhaps kilometer/s and kilogram/s are long words. Therefore we cut off the parts.
in American English, we also sometimes shorten them: kilometer as "k", for instance, "i just ran a 5k"; and kilogram as "kilo", for instance "he said that it weighed 50 kilos - is that heavy or light?" Americans aren't terribly familiar with the metric system though, so more often the whole word is pronounced...