New to React and Installing Questions

I’m on the
Ravenous: Part 1
to start installing create-react-app and I’m confused about installing it thru command line it seems the lesson is outdated and I’m not sure to use npm or npx to install. I’m also confused about what the difference is because it says npx requires npm to be a certain version
https://create-react-app.dev/docs/getting-started/
or
https://github.com/facebook/create-react-app
And I"m confused where I actually use the command
npx create-react-app my-app
or
npm install -g create-react-app

Is it under the Users/username directory?