Semiparametric Transformation Models with Time‐Varying Coefficients for Recurrent and Terminal Events