The rubber strip below the belt molding is for aesthetics, appearance, the tape is ugly.
The rubber strip may provide a barrier between the chrome and the door to protect the paint from an impact but at this point in the cars life it doesn’t matter.
The name of the part is “belt molding”. You can remove these belt moldings and try to find a supply of rubber to replace these failing strips but it seems like a lot of work for little return.
They are similar on my Corolla but mine are painted black.That fake chrome could be sanded down,primed and painted with black or chrome trim paint.The thin strip that is coming off can be remove completely because its not needed.