Focal length is still focal length. The shortening when not at infinity is lens behaviour, not focal length .
Well, "lens behaviour" is a metaphor as well, and a notably vague one. So is "infinity", though not so vague.
The focal length of a lens is the distance from the rear principal plane to the plane in which the image of an object at infinity is in sharp focus. So focal length is a theoretical quantity because nothing is infinitely distant. Objects closer to the lens than infinity are in sharp focus at greater distances from the rear principal plane than the focal length, and an alternative way of putting it is that the focal length is the shortest distance from the real principal plane to the sensor/film at which anything can be in focus. That is a handy thing to know if you are using a view camera, but it has no particular importance for cameras with fixed lens to sensor/film distances. Focal length is used because everyone is used to it, but angle of view would at least as good and in some ways better as a descriptor (because then you would not have people thinking that an 18-140 lens has a bigger zoom range than a 16-80).
An internal focusing lens does not have a single focal length: it focuses closer by changing the focal length. Of course, for descriptive purposes we use the infinity focal length, but that is perfectly arbitrary (and handy for advertising, because that is always the longest focal length). But the focal length at infinity is no more
the focal length than any other.