The phpcs path will be automatically configured by PHPStorm if you do “composer install” through it’s interface. You only require that if phpcs is installed globally.
You just need to run composer from PHPStorm once after you add PHPCS. After it’s run once, the setup will be done. Then you can run composer the normal way from the command line as you prefer.