Wash the leeks thoroughly and then thinly slice. You want the white and light green parts only.
Turn the Instant Pot on sauté. Add the olive oil, leeks, and garlic and heat just until the leeks begin to soften.
Add the potatoes, vegetable broth, thyme, pepper, salt, chili flakes (if using), and bay leaf and give a gentle stir.
Place the lid on the pot, turn the valve to sealing, and set to high pressure (manual) for 8 minutes.
When the timer is complete, let the pot naturally release for 10 minutes. After 10 minutes carefully quick release the remaining pressure.
Remove the lid from the pot and remove the bay leaf. With an immersion blender, blend the soup until smooth, or if you preferred you can leave it a bit chunky. Add the lemon juice and stir.
Ladle soup into bowls and garnish with some sliced green onion if desired. Serve warm.
Notes
If you don't have an immersions blender, you can blend the soup in batches in a blender. Just be careful not to fill the blender more than 2/3 full at a time.