First of all, these phrases sound very strange to me (I should have the context they are used into, in order to have a better understanding of them).
In Spanish such phrases may be an example of that is knoun as "Complemento del Nombre". I'm not sure if such a concept exists in English grammar. In Spanish you must think of that complement as some sort of adjective that specifies the role of the main noun.
Its structure is:
[Main Noun] de [Specifier Noun]
So, with the phrase "Fiestas de árboles", you have:
- Fiestas is the main noun.
- árboles is the specifier.
then you may have these meanings (among others, depending on the context):
- Parties attended by trees (should be better expressed with: Fiestas de los árboles).
- Parties made out of trees (parties whose main element are trees).
On the other hand, "Árboles de fiestas" may have these meanings:
- Abbreviation of Árboles que están de fiestas: trees which are going or attending to a party.
- Trees used within parties (should be also expressed with: Árboles para fiestas).
As you can see, at least the meanings I can think of these phrases are very similar for both cases.