Open charm production in high multiplicity proton-proton events at the LHC