You will probably want to use a pixel art program such as Aseprite (or Libresprite, an open source fork) for editing sprites and backgrounds.
For more advanced backgrounds, the Tiled map editor is indispensable.