There are 3 things in Buddhism...
Buddhist philosophy, religion and literature..
Ordinary person does not have mind set to understand the deep bitter truth delivered by philosophy, so it has been been spread as a religion and slowly convey the truth
When Mahinda thero brought Buddhism to Sri Lanka, people were worshiping rocks , trees and so on, so in order to avoid a huge change from their traditions, rock worshiping is slightly changed to chaitya wandanawa, trees to bodhi wandanawa

Those things do not belong to Buddhist philosophy