Try connecting the MacBook to Wi-Fi and restarting it. If it’s been offline for a while, it might need to reconnect to Apple’s servers before it recognizes your updated password. If that doesn’t work, try logging in with your old Apple ID password. Sometimes, macOS stores the last-used credentials for login, even if you’ve changed them elsewhere. Once you’re in, you can update the password in System Settings > Apple ID > Password & Security.
If neither works, boot into Safe Mode (restart and hold Shift until the login screen appears), then try signing in again. If the problem is related to a system glitch or cached credentials, Safe Mode might clear it. Worst case, you might need to reset your password via Recovery Mode—but hopefully, it doesn’t come to that.