Summary
To change the password of a Linux user, do this:
passwd
That will change the currently logged in user’s password.
To change the password of another user, do this:
passwd username
That will change the password of another user.
Reference
https://www.cyberciti.biz/faq/linux-set-change-password-how-to/