Hi Luca, welcome to Elgg!
You should be storing attributes as metadata and not be adding ad hoc tables to the database, the Elgg data model is such that just about anything can be stored as metadata, annotations, plugin settings, or relationships depending on what you need it for.
Of course there will always be a correlation between the amount of metadata and performance, but it's not as bad as you might think. The metadata for an entity isn't retrieved simply by loading the entity, it's retrieved the first time it's used, and stored in memory for the rest of the operation. So if you have an entity with 100 pieces of metadata, and you load the entity and display one piece of metadata, the remaining 99 pieces of metadata are not retrieved.
Additionally, using your own tables to store data essentially takes that data outside of the Elgg framework - thereby making it unavailable for other plugins/extensions. You lose out on the all of the hooks, events, and permissions associated with metadata that are integral to the flexibility of Elgg.
Also, when you decide to optimize, it's possible to flatten DB without modifying the core. For our projects we have a hook-based plugin which handles this quite well for all types of entities. In case you eg. search by 10 or more metadata, you can "cache" them and retrieve with just one join (this one join can be removed as well, although it's a little bit more complicated).
My experience is that Elgg DB is not very well optimized. It can be optimized relatively easily when you start to have need for optimization though.
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.