Inelastic effect on the resonance lineshapes in He-Graphite scattering