EDIT:
If this is happening on mint/ubuntu, it is likely because you installed vscode through the software manager. This will cause other problems during debugging. Instead install it using the .deb file on the vscode website.
If you really want to use the software manager, the solution below still works:
use find / -name code 2> /dev/null
to find the path to the visual studio bin file. It should end in /extra/vscode/bin/code
If you're using the mint software manager, you might only find paths with a ridiculously long name in the middle like this:
".../stable/7a22830d9e8fbbdc9627e43e072005eef66c14d2a4dd19992427ef4de060186a/..."
Just replace the long part with "/active/"
Once you have it, create a sym link:
ln -s path_you_found/extra/vscode/bin/code /usr/local/bin/code
If you don't have the rights, or only want it to be accessible for yourself, simply add this line to your .bashrc / .zshrc:
export PATH="$PATH:path_you_found/extra/vscode/bin/
Note that I removed the 'code' filename at the end