I know 単位 can indicate unit of measurement, but I can't really understand what does it adds, and if it's needed or something extra; I also tried on Weblio, but while I understand the definition, I don't really understand its usage.
Here's an example; as context, an alien is approaching the spaceship, and the commander asks about its distance; the answer is:
What I don't understand is: would the sentence be grammatical also without 単位, like "あと9000キロです"? If yes, what does it add? If not, is there any case in which removing it is right? I think for example about the title "いつだって僕らの恋は10センチだった".