Influence of Fano effect on magnetic circular dichroism due to core electron transition in Ni and Gd metals