Steps:
1. Start a new project, choose class library.


2. The class libary project name is used for the namespace name.
3. Add class: Right click on class library project > Add > New Item... > Visual C# Items > Code > Class

4. Note: if you add a class in a folder, Namespace will be [Namespace].[folder]. Just delete the folder name in the namespace if you want to simplify class library namespace name.
5. To use a class library within a project, add the class libary reference to the project.

6. To access properties/methods of a class library, make sure the access modifier is 'public' for the class

Note: You can check that your project is a class library in properties:

Class Library project templates:
In latest versions of visual studio, you can select whether to use an empty class library or one with an asp.net framework:
Eg:
