ADM mass of a black hole and mass of the associated matter The ADM formalism gives a definition for the energy (Hamiltonian) of a static, asymptotically flat spacetime. This energy can be equated to the mass of the matter (for example, a black hole) which resides in this spacetime.

What is the physical mechanism which allows us to equate the energy of a spacetime with the mass of the matter which resides in the spacetime?
 A: The ADM mass is the total energy (with c=1) of a spacetime, as defined by an observer at spatial infinity, using the Hamiltonian formalism, for an asymptotically flat spacetime. It's calculated in Carroll. But even better see the discussion and answers in the PSE answers referenced below.  
So the physical reason is that it is the total energy in the spacetime, for asymptotically flat spacetimes,I.e., isolated systems. 
Also, you can get the approximation of the metric for large r and compare it to the formula for a weak field, also giving M
The Hamiltonian formalism is derived from the Lagrangian which also can be used to get the EFE. Energy is defined wrt what the observer picks as his/her time coordinate.   
You can calculate that entity and for the Schwarzschild metric it gives you the M in the metric. 
Note that also you can get M from the spacetime being static, i.e., the metric is time independent and thus it has a symmetry defined by a Killing vector field, in this case the t direction. The entity conserved is called the Komar mass, and it also you can calculate to be M. Finally the Bondi-Sachs mass is also M, calculated at lightlike infinity. 
Notice also that the calculated ADM mass would in general (say for non-static non Schwarzschild spacetimes)include the mass of any gravitational energy radiated to infinity, so it does not measure separately the mass loss due to radiated gravitational radiation. The Bondi-Sachs mass does separate those, and the Bondi mass loss function is used to calculate the gravitational radiation energy radiated to infinity (it uses lightlike infinity, so it describes radiation as outgoing flux). The Bondi mass function was used to calculate the total energy in the gravitational wave emitted in the merger of the two black holes in 2015. The metric was not Schwarzschild, and approximations/numerical results needed to be done to get the 3 solar masses estimated.
The validity and meaning of ADM mass is also discussed in the PSE answers at How do we know the Schwarzschild solution contains an object of mass $M$?
