Key money is directly translated as "thank you money".
It is money given by a tenant as an expression of gratitude for being able to rent a property. There are many theories as to how this custom began, but it is known that it was once a means of securing housing during World War II and the shortage of properties during the industrialization era. It also seems to have had a kind of insurance aspect, with the landlord taking care of the children while the parents were away.
More recently, there has been a trend toward eliminating the need for key money. Key money has not disappeared in the current market, but there are fewer and fewer properties that require it.