How do we check the availability of compatible donor for a patient?

Cross match. Simply out in 3 ways: 1) making sure patient blood type is same or compatible with the donors. 2) mixing donor red cells with patient blood in a tube to see if there is any reaction. 3) screening patient's blood for any antibodies. If present, compatible blood is chosen to avoid complimentary antigens in donor blood.
Donor of what? Blood, solid organs, and bone marrow all have different compatibility criteria.