Dependency Injection
Start developing with C#
Containers
What is a container?
A container is a abstract concept but in reality it is a class that is used to manage the lifetime of objects in your application.
So whenever you need to create an object, you can ask the container to create it for you or you can ask the container to give you an instance of an object that has already been created.
For example in Entity Framework, which is a ORM (Object Relational Mapper) that allows you to interact with a database using C# objects.

But what is a ORM?
An ORM (Object Relational Mapper) is a programming technique used to convert data between incompatible type systems in object-oriented programming languages.
The most common use of ORM is to map database tables to classes in your application.
This allows you to interact with the database using C# objects instead of writing raw SQL queries.
So to be clear, you don't need to use an ORM, but it makes life easier when working with databases if you don't want to remember raw SQL queries.
ORMs also provide features like lazy loading, change tracking, and caching, which can improve performance and reduce the amount of code you need to write.