Why?
As has already been explained to you through extensive quotation from the case and in great detail, it was necessary to determine where the court got its authority to issue writs, if that authority was constitutional, and if that authority was presently in place for the case. The answer to all these questions derives from the Habeas Corpus clause in Article I, which the court found to apply to congress.