Given a class F of metric spaces and a family of transformations T of a metric, one has to describe a family of transformations T′ ⊂ T that transfer F into itself and preserve some types of minimal fillings. The article considers four cases. First, when F is the class of all finite metric spaces, T = { (M, ρ)→ (M, f ◦ρ) | f : R>0 → R>0 } , and the elements of T′ preserve all non-degenerate types of minimal fillings of four-point metric spaces and finite non-degenerate stars, and we prove that T′ = { (M, ρ) → (M, λρ + a) : a > λaρ } . Second, when F is the class of all finite metric spaces, the class T consists of the maps ρ → Nρ, where the matrix N is the sum of a positive diagonal matrix A and a matrix with the same rows of non-negative elements. The elements of T′ preserve all minimal fillings of the type of non-degenerate stars. It has been proven that T′ consists of maps ρ → Nρ, where A is scalar. Third, when F is the class of all finite additive metric spaces, T is the class of all linear mappings given by matrices, and the elements of T′ preserve all non-degenerate types of minimal fillings, and we proved that for metric spaces consisting of at least four points T′ is the set of transformations given by scalar matrices. Fourth, when F is the class of all finite ultrametric spaces, T is the class of all linear mappings given by matrices, and we proved that for three- point spaces the matrices have the form A = R(B + λE), where B is a matrix of identical rows of positive elements, and R is a permutation of the points (1, 0, 0), (0, 1, 0) and (0, 0, 1),