You will most often use Bash functions to make your shell life easier; instead of typing out complex command pipelines, create a function and inject arguments. You'd place these in your bashrc file, ...
As a beginner to writing scripts with PowerShell, you won't learn the concept of a function until later. Newbies typically learn about PowerShell functions after they've learned what the pipeline is, ...
By defining Microsoft PowerShell functions within PowerShell modules, you can organize your scripts, avoid duplicating code, ...