Numerical evolution of matter in dynamical axisymmetric black hole spacetimes: I. Methods and tests