If you want some background, jpeg is a lossy format; it means that to achieve better compression, it removes some information from your image, based on the fact that human eye does not react to every colors in the same way. That kind of compression can create "artifacts" in the image, that results in some visible blocks. And jpeg is quite bad with large patch of the same color.
On the other side, png is a lossless format, it encodes every details of your image, in the trade of file size. But png is quite good at it's job.
If you want to compare, I did a screenshot in minetest and saved it two times, one in png and one in jpeg (with quite low quality). Then I enlarged both and here is the result:
PNG:

JPEG:

So, for a game like minetest, you would be quite disappointed if the default image format would be jpg; no way to get a good quality screenshot.
And so, yes png is the best format in that case; and supporting another export format means adding options (format, compression quality), another library as dependency, and code to maintain...
And probably at the end, you will open the screenshot before posting it to a web site; either to resize it or to add some watermark or ...
My opinion is that it's probably better to focus on other part of the engine before the screenshot format :) (but who knows, if you come with code and a pull request...)