First you will need to remove the mantle. Use a screwdriver or a drill with an old bit and unscrew all of the screws holding it in place. Then lift it off, being careful not to damage the brick underneath if there is any.
Now that your hearth has been removed from its original location, you can cut through any mortar joints surrounding where the frame previously sat. You should be able to see four nails around this area which secure it into place so use a pry bar to take them out.
Once all of the nails are removed you should be able to pull the frame back out easily.
At this point, you can cut through any remaining mortar joints and remove bricks wherever they may still remain. Use a chisel or brick hammer for this purpose as well as an old bit on your drill if necessary. Once that is done clean up any dust with a damp rag before finishing it off by adding new mortar. It’s best to consult someone who has experience in doing so but using either pre-mixed grout or premixed fire place refractory cement will work great!