The Gnu Image Manipulation Program is a powerful and popular pixel pushing program, and a free software competitor to Adobe Photoshop. Its main interest for ZDoom modders is probably to edit PNG files.
To save a PNG with the Doom palette for latter conversion to Doom graphic files, you can save this file in your GIMP/share/gimp/2.0/palettes folder (the GIMP folder will typically be
%APPDATA%\GIMP\2.10\ on Windows systems and
~/.gimp/ on Linux systems).
This file contains a similar palette for Heretic, and this one contains one for Hexen.