How do I rename an item with add-ons?

Solution 1:

To rename items, in your resource pack, create a texts folder in the root directory. In texts, create a file that is the language code .lang. For example, United States would be en_US.lang, and the United Kingdom would be en_GB.lang. There is a different file for each language.
In each file, in the language it is in, to rename blocks, do this:

tile.block-id.name=Custom Name

And to rename items, do this:

item.item-id.name=Custom Name

If it is a custom item or block, use

tile.pack-name:blck-id=Custom Name

or

item.pack-name:block-id=Custom Name