On the basis of ab initio calculations, we report the phase transformation of Mn3Si Heusler alloy from austenite to martensite structure. The total energy calculations suggest that the antiferromagnetic (AFM) spin configuration phase has the lowest energy and at a compressed volume Mn3Si becomes ferromagnetic (FM). We focus upon the distortion of the cubic Heusler structure which induces tetragonal structure with space group I4/mmm. We find out that, at c/a ratio of 1.60 and 1.38, the FM and AFM tetragonal structures become stable unlike the cubic ones. Consequently, martensitic transformation is expected to occur in both FM and AFM Mn3Si alloy. The stability of the martensite phase with respect to the austenite one is confirmed by calculating the density of states (DOS) at the Fermi level.