Input with variable length Classification problem
The goal is to predict the current stage for one patient, so for the classification part you must have a single instance for every patient. So the question is how to transform your features repeated for every visit into a fixed number of features.

The standard option is to use expert knowledge to engineer the features. For example there might be some features which are only relevant at a certain point in time and no longer relevant later, so for these you can just keep the latest value. There might be some features for which the evolution across time is significant, so for example the average increase in the past N months might make sense. The idea is to "summarize" any number of visits into a fixed number of features.

A more advanced option would be to "vectorialize" your features, i.e. generate some kind of embedding using some unsupervised deep learning method (but that's not my area of expertise).