(A) and (B) are compounds with same molecular formula C2H6O.
(A) reacts with metallic Na and liberates H2 ↑
∴ (A) is ethanol [CH3CH2OH]
(B) is methoxy methane [CH3OCH3]

(A) reacts with ethanoic acid and forms ester.

(A) Ethanol, CH3CH2OH
(B) Methoxy methane, CH3OCH3
(C) Ethyl ethanoate, CH3COOC2H5