Tunable crossover between one- and three-dimensional magnetic dynamics in C o II single-chain magnets organized by halogen bonding