We consider location problems to find the optimal sites of placement of a new facility, which minimize the maximum weighted Chebyshev or rectilinear distance to existing facilities under constraints on a feasible location domain. We examine Chebyshev location problems in multidimensional space to represent and solve the problems in the framework of tropical (idempotent) algebra, which deals with the theory and applications of semirings and semifields with idempotent addition. The solution approach involves formulating the problem as a tropical optimization problem, introducing a parameter that represents the minimum value of the objective function in the problem, and reducing the problem to a system of parametrized inequalities. The necessary and sufficient conditions for the existence of a solution to the system serve to evaluate the minimum, whereas all corresponding solutions of the system present a complete solution of the optimization problem. With this approach, we obtain direct, exact solutions represented in a compact closed form, which is appropriate for further analysis and straightforward computations with polynomial time complexity. The solutions of the Chebyshev problems are then used to solve location problems with rectilinear distance in the two-dimensional plane. The obtained solutions extend previous results on the Chebyshev and rectilinear location problems without weights and with less general constraints.