With Mr. Fantastic and Plastic Man as probably the best known examples, superhero comics have a diverse group of characters whose primary or exclusive power is to stretch their bodies into improbable shapes. The earliest example of such a character I'm able to find is Thin Man from Marvel predecessor Timely Comics. Are there any older examples?
The earliest "stretchy" superheroes seem to be The Thin Man and Flexo the Rubber Man, both of whom debuted in Mystic Comics #4 in July, 1940. Both superheroes (kinda) had stretching powers with The Thin Man capable of making himself thinner and Flexo (no, not that one) capable of using his flexible rubber shell to twist and rotate at high speeds.
The first superhero capable of actually stretching themselves into other forms appears to be Plastic Man who debuted in Police Comics #1 in August, 1941
Followed by other heroes like Elastic Lad (Superman's Pal, Jimmy Olsen #31 - Feb, 1958) and Mr. Fantastic (The Fantastic Four #1 - Nov, 1961)
You may wish to note that the concept of a stretching character dramatically pre-dates Western comic books, with traditional Japanese rokurokubi (from the 1600s) depicted in storybooks as having stretchy and detachable necks.