What happens in Bank Guarantee usually is that bank makes sure that the person on whose behalf its giving guarantee has a worth more than the amount mentioned in such guarantee. Usually banks take cash amounts from that person or mortgages his her property as surety.
A common trend is that Bank Guarantees are exchanged in international transactions against the goods purchased. That brings confidence on the part of seller that he/she will be get paid eventually by the purchaser. Similarly the purchaser knows that he/she will get the product for sure as per the settled terms.
If you are facing any legal complications regarding the bank guarantee, do write us at firstname.lastname@example.org