CLOSEDNESS PROPERTIES OF INTERNAL RELATIONS I: A UNIFIED APPROACH TO MAL'TSEV, UNITAL AND SUBTRACTIVE CATEGORIES