There are some cases where hiding the plaintext length is desirable (e.g. if the plaintext by destination is either "yes" or "no", or if that plaintext is a password).
However, hiding the length of the plaintext is not a standard goal for encryption. Many modern encryption methods make it trivial to find the exact plaintext length from the ciphertext (e.g. CTR, GCM), and about every other makes it possible to get an approximation of the length, e.g. recognize "Bob Lee" from "Emmanuella Wolfeschlegelsteinhausenbergerdorff".
Knowing the length will slightly help in some cryptographic attacks, but does not by itself give adversaries a padding oracle. That issue can only happen if [the receiving end checks that length] AND [the encryption system uses padding].
Therefore putting the length along the ciphertext is generally OK, as long as: [that length is not by itself secret] AND [[that length is ignored by the decryption code] OR [the encryption system does not use padding]].
Authenticated encryption that does not use padding include ChaCha20-Poly1305, AES-GCM, AES-GCM-SIV, AES-CCM, AES-OCB, AES-CWC, AES-EAX. Non-authenticated (thus less recommendable) encryption that does not use padding include AES-CTR, AES-OFB.