The shepherd is a man who has shown a certain amount of bravery saving an abandoned child on a mountain side. Rather than leaving the baby to his fate (certain death), he makes sure he is cared for. Providence steps in and Oedipus becomes the cherished child of a king—Polybos.
Now that his actions are being questioned so many years later, it is not a surprise that the shepherd is at first hesitant to reveal what he knows. After all, he is only a shepherd. We already know that a king could do anything he wanted—if we think back to the crossroads where Oedipus and Laius meet. If Laius would kill someone for not giving him the right of way on a road, it is probably not cowardice but a healthy sense of self-preservation that keeps the shepherd silent at first. "He who fights and runs away, may turn and fight another day." (Tacitus) It's wise to speak wisely, and live to see another day. I see no cowardice in this.