Structural and electronic properties of Cu4O3 (paramelaconite): the role of native impurities