Playing .10/.25 NL on Poker.com. Don't know a whole lot about the players quite yet. Don't know exactly everything but enough to make the situation

Hero in SB with K-K (22)
Villain UTG

Villain limps, UTG+1 limps, 2 folds, Hero raises to 1.25, Villain calls, UTG+1 calls.

Flop: 5c-6c-8h (4.00)
Villain checks, UTG+1 checks, Hero bets 4, Villain goes all in for 19. Hero????

Turn: 9h

River: Qc

Results posted in white
Villain shows 9c-4c for flush and wins 40 pot

*The only hand I could put him on was an underpair to mine or overcard bluff because the pot was big. Guess people at this level don't think a big raise in the SB means something?

Hand 2.

Hero Ac-Jh UTG (20.00)
Villain in SB

Hero calls, SB calls, BB checks

Flop: Ad-Jd-2s
Villain bets 2, Hero raises to 5.50, villain calls

Turn: 8d
Villain goes all-in for 15....Hero thinks and dreads the call but I put him on an ace and was hoping he had a-k, a-q and not a flush

River: Qh
Results in white

Villain wins pot with two pair: Aces and Queens

My flop raise was weak, but like I said I wanted him to stay along hoping he was on the ak or aq or worse without the flush draw. Would you have called these all ins? I have told myself one of my leaks is calling these huge bets without the near nuts because most of the time they turn over a set or a flush. would you just fold to these big bets without the near nuts? Thanks.