The 14.1 MeV neutron irradiation in fusion reactors can cause significant damage to tungsten (W), leading to defect formation and the creation of various transmutation elements, with rhenium (Re) being a principal product. Hydrogen isotopes are essential as fuel for fusion reactors, but the presence of transmuted Re complicates the behavior of hydrogen isotopes in W. This study systematically investigated the behavior of hydrogen isotopes in W and W-5%Re by molecular dynamics methods. The results indicate that Re in the W bulk significantly influences the retention, desorption, and diffusion behaviors of deuterium (D). Specifically, the inhibitory effect of Re on D retention decreases with increasing temperature, and the differences in D retention between W and W-5%Re are closely linked to vacancy concentrations. The addition of Re effectively reduces these vacancy concentrations, with even small amounts proving significantly in decreasing D retention. Furthermore, the amount of D desorbed from W is higher than that from W-5%Re at a desorption temperature of 500 K. The presence of Re also increases the diffusion coefficient of D in W, although this coefficient remains relatively stable regardless of Re concentration. Regarding depth distribution, D enrichment is more pronounced near the surface of W than in W-5%Re, closely linked to vacancy concentrations. As temperature increases, more D atoms diffuse into the material's interior, with Re in the bulk of W promoting this diffusion and mitigating surface damage. This study enhances understanding of the impact of Re on hydrogen isotope behavior and supports future assessments of tritium behavior under neutron irradiation conditions.