This paper addresses the railway rolling stock rescheduling problem, while taking maintenance appointments into account. After a disruption, the rolling stock of the disrupted passenger trains has to be rescheduled to restore a feasible rolling stock circulation. Usually, a number of train units have a scheduled maintenance appointment during the day: these appointments must be taken into account while rescheduling the rolling stock. In this paper we propose three mixed-integer programming models for this purpose. All models are extensions of the composition model from the literature, which does not distinguish individual train units. The extra unit type model adds an additional rolling stock type for each train unit that requires maintenance. The shadow-account model keeps track of a shadow account for each train unit that requires maintenance. The job-composition model creates a path for each train unit such that the train units that require maintenance are on time for their maintenance appointments. All models are tested on instances of Netherlands Railways. The results show that especially the shadow-account model and the job-composition model are effectively able to take maintenance appointments into account during real-time rescheduling. It depends on the characteristics of an instance whether the shadow-account model or the job-composition model performs best.