Where should place for the custom interfaces and classes


I’m beginner in Yii2. I couldn’t found information by my question. Tell me please, where a better put my interfaces and classes they shouldn’t declare as components?

To custom directories/namespaces that correspond to your classes and interfaces meaning.

Hence I can create my own directory anywhere in within the yii installation. Right?