A body is said to be in motion:
When it changes its position with respect to an observer
A body is said to be in motion only if it changes its position with respect to an observer. Suppose two bodies are moving together, they change their position even though one body is at rest with respect to the other.