It sounds like your system may not be properly configured.
The first step is to check to see which version of SPFx you have installed. You can do this by running npm list -g --depth=1 @microsoft/generator-sharepoint
.
You then need to check that you are using a compatible version of Node.js. The SharePoint Framework development tools and libraries compatibility page in the Microsoft documentation has a table you can consult.

If you have a compatible version of Node.js installed, the last thing to check is whether you have Gulp or Gulp CLI installed globally. Microsoft recently changed their guidance from installing Gulp to installing Gulp CLI.
You can check to see if you have Gulp installed globally by running npm list -g --depth=1 Gulp
. You should uninstall it if it is installed by running npm uninstall gulp --g
. You should then install Gulp CLI by running npm install gulp-cli --global
.
If you do end up changing Node.js versions or if you switch from using Gulp to using Gulp CLI, you may need to clear you npm cache to ensure things work as expected. You can do this using npm cache clean –force
.