public void RegisterUser()
        {
            int    age;
            string name;
            string surname;
            string country;
            string login;
            string password;
            string email;
            string phoneNumber;

            Console.Write("Enter age(You have to be over 18 years to register on site):");
            age = Int32.Parse(Console.ReadLine());

            try
            {
                if (age < 18)
                {
                    UserRegistrationException ex = new UserRegistrationException(string.Format($"Persons under 18 years cant register"));
                    throw ex;
                }
                else
                {
                    Console.Write("Enter name:");
                    name = Console.ReadLine();

                    Console.WriteLine();
                    Console.Write("Enter surname:");
                    surname = Console.ReadLine();

                    Console.WriteLine();
                    Console.Write("Enter country:");
                    country = Console.ReadLine();

                    Console.WriteLine();
                    Console.Write("Enter login:"******"Enter password:"******"Enter phone number:");
                    phoneNumber = Console.ReadLine();
                    Console.WriteLine();
                    Console.Write("Enter email:");
                    email = Console.ReadLine();


                    User user = new User(name, surname, country, login, password, email, phoneNumber, age);
                    if ((!users.ContainsKey(email)) && (!admins.ContainsKey(email)))
                    {
                        users.Add(user.Email, user);
                    }
                    else
                    {
                        do
                        {
                            Console.WriteLine("Cant register user with same email is already exists");
                            Console.Write("Enter your email:");
                            email = Console.ReadLine();
                        } while (users.ContainsKey(email) || admins.ContainsKey(email));
                        user.Email = email;
                        users.Add(user.Email, user);
                    }
                }
            }
            catch (UserRegistrationException e)
            {
                Console.WriteLine(e.Message);
            }
        }
        public void RegisterAdmin()
        {
            int    age;
            string name;
            string surname;
            string country;
            string login;
            string password;
            string email;
            string phoneNumber;

            Console.Write("To register a new admin you have to enter codeword:");
            string adminCode = String.Empty;

            adminCode = Console.ReadLine();
            if (adminCode == Admin.adminCode)
            {
                try
                {
                    Console.Write("Enter age(You have to be over 18 years to register on site):");
                    age = Int32.Parse(Console.ReadLine());
                    if (age < 18)
                    {
                        UserRegistrationException ex = new UserRegistrationException(string.Format($"Persons under 18 years cant register"));
                        throw ex;
                    }
                    else
                    {
                        Console.Write("Enter name:");
                        name = Console.ReadLine();

                        Console.WriteLine();
                        Console.Write("Enter surname:");
                        surname = Console.ReadLine();

                        Console.WriteLine();
                        Console.Write("Enter country:");
                        country = Console.ReadLine();

                        Console.WriteLine();
                        Console.Write("Enter login:"******"Enter password:"******"Enter phone number:");
                        phoneNumber = Console.ReadLine();
                        Console.WriteLine();
                        Console.Write("Enter email:");
                        email = Console.ReadLine();
                        Admin admin = new Admin(name, surname, country, login, password, email, phoneNumber, age);
                        if ((!users.ContainsKey(email)) && (!admins.ContainsKey(email)))
                        {
                            admins.Add(email, admin);
                        }
                        else
                        {
                            do
                            {
                                Console.WriteLine("Cant register user with same email is already exists");
                                Console.Write("Enter your email:");
                                email = Console.ReadLine();
                            } while (admins.ContainsKey(email) || users.ContainsKey(email));
                            admin.Email = email;
                            admins.Add(email, admin);
                        }
                    }
                }
                catch (UserRegistrationException e)
                {
                    Console.WriteLine(e.Message);
                }
            }
            else
            {
                Console.WriteLine("You entered invalid admin code,please register later or contact with other admins");
            }
        }