Default screenshots location on Macs is your Desktop which is not very convenient. After a few months, it will look (probably always) like one big mess with a lot of random files scattered around. Wouldn't be great to store all your screenshots in one place?
In order to adjust screenshot location follow these steps:
Execute (you may adjust location by changing the last part with path
~/Documents/Screenshotsto fit your needs):
defaults write com.apple.screencapture location ~/Documents/Screenshots
There is one catch. Target directory has to exist before executing that command, this is an advice from my personal experience.
Execute to apply changes:
A custom file format can be set in a way similar to a custom location, just in step
defaults write com.apple.screencapture type jpg
You may adjust
type jpg to suit your needs here is a list of available values: