Study of Mg resonances relevant for Carbon burning nucleosynthesis