As one person, you can not hold a court if two people are waiting - EVER. Everyone used to abide by this rule of tennis etiquette, but now people are selfish and any sense of what it means to be a good person is gone.
You weren't playing singles or doubles, if you were, there are usually posted rules but local custom usually overrides those. Some places people usually invite the others to play doubles. Some places it is expected that you play as long as you want, while the people waiting know that once they get a court, they can play as long as they want. Some places the posted rules are followed and people waiting will time you and get in your face if you stay too long.