The answer depends on what the elements are. Let's say for the sake of example they are a data set and a bar chart task -- the bar chart uses the data as input.
To insert a query in the middle, first right-click on the data and select Filter and Query. Design the query as you want and run it.
This creates another data node -- the output from the query.
Right-click on the bar chart node in the process flow and click Select Input Data, selecting the new data output table you just created (don't select the query itself -- that's the one with the little filter in the icon).
Result: the process flow redraws with the query and its output in between the original input data and the bar chart. Rerunning the bar chart will pick up the new input.
Chris