When botanists talk about berries, they mean a simple fruit produced from a single ovary. They sometimes call this true berry, to distinguish it from false berries. By that statement of how words are used, grapes or tomatoes are true berries.
The berry is the most common type of soft fruit in which the entire ovary wall gets to the right stage of development of the pericarp which can be taken as food. The flowers of these plants have an upper ovary with one or more carpels. The seeds are inside the soft body of the ovary.
Some fruits that are called berries in English are not true berries by the use of words above. These include raspberries, strawberry, blackberries, cranberries, and boysenberries. Some true berries do not have berry in their name. These include tomatoes, bananas, eggplants, guavas, pomegranates and chillies. Pumpkins, cucumbers, melons, oranges and lemons are also berries that have slightly different structure and may be called by different names (pepo for pumpkins, cucumbers, and melons, or hesperidium for oranges and lemons).