High Sierra not recognizing username when entering credentials
Assuming you have a system installed that is new enough to allow you to boot into Recovery mode (hold ⌘-R at startup, if not, use the disk as explained in the article), I think this may help you. Oops, forgot your question title. Look for Terminal in the Utilities menu after you get into Recovery mode. "resetpassword" still works, even in High Sierra.

Use OS X Recovery Disk Assistant to reset Your files and folder permissions