Defect-induced monopole injection and manipulation in artificial spin ice